A similar error happens even with tr1 result_of (i.e. without defining
BOOST_RESULT_OF_USE_DECLTYPE).
Minimal test case (fails to be compiled):
#include
template <typename T>
struct my_less
{
bool operator()(T const& t1, T const& t2) const { return t1 < t2; }
template <typename Sig> struct result;
template
struct result
{
typedef bool type;
};
};
int main (int argc, char* argv[])
{
boost::void_ptr_indirect_fun f;
return 0;
}
The error occurred in the code (at line 105 of ptr_container/indirect_fun.hpp)
which determines the return type of unary function call operator of
class boost::void_ptr_indirect_fun:
result_of::type operator()( const void* r ) const {...}
Since result_of only works with two function parameters,
this code does not compile.
These issues, including OP's one, can be fixed by removing unary function call
operator of class boost::void_ptr_indirect_fun (i.e. making it BinaryFunction).
Hope this helps,
Michel