Callback parameter for lamdas and member functions
I have this function:

    void func(boost::function<void(float)> cb){
    //do something with cb()
    }

It works with lambdas and functions.
But it does not allow me to pass a member function or a lambda defined in a member function. 

I tried to cast something like this:

    void class::memberFunc() {
    void func((void(*)(float))([](float m){}));
    }

But it seems like lamdba is ignored at calls.
And no idea how to pass a member function too.

Thanks ahead!
Callback parameter for lamdas and member functions
===

I have this function:

    void func(boost::function<void(float)> cb){
    //do something with cb()
    }

It works with lambdas and functions.
But it does not allow me to pass a member function or a lambda defined in a member function. 

I tried to cast something like this:

    void class::memberFunc() {
    void func((void(*)(float))([](float m){}));
    }

But it seems like lamdba is ignored at calls.
And no idea how to pass a member function too.

Thanks ahead!