I\'m using g++ 4.7.
What I\'m trying to do is this,
find_if(s.begin(), s.end(), isalnum);
where isalnum
This should work.
#include <algorithm>
#include <cctype>
auto result = std::find_if (begin(s), end(s), std::isalnum);
This should work
#include <algorithm >
#include <cctype>
auto result = std::find_if(std::begin(s), std::end(s), isalnum) ;
The compiler is having trouble disambiguating between this function and this function. You want the first one, and you'll have to help the compiler out here, by specifying the signature with a cast:
find_if(s.begin(), s.end(), (int(*)(int))isalnum);