Here is a code:
#include using namespace std::tr1; typedef void(*fp)(void); void foo(void) { } void f(fp) { } int main() { functio
You can't convert a std::function to a function pointer(you can do the opposite). You should use either function pointers, or std::functions. If you can use std::function instead of pointers, then you should.
std::function
This makes your code work:
typedef function fp;