To my best knowledge: void (A::*p)() = &A::test_func;
means that p
is a pointer to the member function void A::test_func()
, and std::mem_fn(...)
can be used to wrap a pointer to a member function.
But in the following code snippet I couldn't translate what void (Handler::*)()
and Handler::*member_fn
mean.
class Handler;
std::pair<boost::shared_ptr<Handler>, void (Handler::*)()> cb = job_queue.sync_pop();
void (Handler::*member_fn)() = cb.second;
(cb.first.get()->*member_fn)();