
2 Aug
2004
2 Aug
'04
12:06 p.m.
What is the prefered method of creating a boost::function<void()>, via boost bind, that is calling a member function of a class, and that class instance is held inside the bind object as a weak ptr. Thus, when the function is called, it will try to lock the shared_ptr, if successful it calls the bound function, otherwise it does nothing. Is there an standard way of doing this? Or do I have to write my own custom intermediate function? (which is how I do it now). Jeff