#include #include #include using namespace boost::phoenix::placeholders; using namespace boost::phoenix; int main() { char X('x'); find(boost::as_literal("fox"), 'x')(); // works #ifndef BOOST_NO_CXX11_DECLTYPE const char *Y = find(boost::as_literal("fox"), arg1)('x'); // works for C++11 #else const char *Y = find(boost::as_literal("fox"), construct(arg1))('x'); // works #endif BOOST_TEST(X == *Y); }