#include #include struct my_func { typedef void result_type; void operator() (int& n) { ++n; } }; int main(int, char*[]) { int n = 0; my_func f; boost::phoenix::bind(f, boost::ref(n))(); return n; }