Hi, I am doing a project comparing run times of STL sorts to sorts i have written. I am having a really weird compiler error that looks like this:
Here is some of the code from my main:Code:main.cc: In function 'int main(int, char**)': main.cc:56: error: 'sort' cannot be used as a function
when i comment out the line that calls sort() everything works fine... even stable_sort which is from the same library and uses the same parameters. Also i have another small program just one file that calls sort() and it works there fine. This is completely insane and i cannot figure it out and any hints would be great.Code:switch(sort){ case 'q': if(stl) sort(my_vect.begin(), my_vect.end()); else quick_sort(my_vect); break; case 'm': if(stl) stable_sort(my_vect.begin(), my_vect.end()); else merge_sort(my_vect); break; ...
thanks