
7 Mar
2005
7 Mar
'05
2:57 a.m.
std::sort(vec.begin(), vec.end(), boost::bind(std::less<int>(), *_1, *_2));
deref.cpp:154: error: no match for 'operator*' in '*<unnamed>::_1' deref.cpp:154: error: no match for 'operator*' in '*<unnamed>::_2'
Am I missing something?
If I remember correctly, the Boost.Bind placeholders (_1, _2, etc) work for non-operator usage. The Boost.Lambda placeholders support all the operator overloads. kalin