On Oct 1, 12:24 pm, Pedro Lamarão <[EMAIL PROTECTED]> wrote: > On Sep 29, 8:37 pm, er <[EMAIL PROTECTED]> wrote: > > > hi, > > > for example, i use > > > boost::bind( > > &A::f, > > _1 > > ) > > > in different parts of my code. i'm thinking of using something like > > > some_type* fo = new boost::bind(&A::f,_1); > > > and use *fo in place of boost::bind(...). is this ok? what should > > some_type be? > > This is a question most suited for the Boost Users mailing list. > > Check the Boost website. > > http://www.boost.org/ > > -- > Pedro Lamarão
thanks, news://news.gmane.org/gmane.comp.lib.boost.user helped, but still have a problem: boost::function<void(const boost::shared_ptr<A>&)> deref = boost::bind(&boost::shared_ptr<A>::operator*, _1); Functor ftor; std::vector<boost::shared_ptr<A> > vec = ...; for_each( vec.begin(), vec.end(), boost::bind( boost::ref(ftor), boost::bind(&boost::shared_ptr<A>::operator*, _1) ) );//fine for_each( vec.begin(), vec.end(), boost::bind( boost::ref(ftor), deref ) );//not fine. see error below //no match for call to '(Functor) (boost::function<void ()(const //boost::shared_ptr<A>&), std::allocator<void> >&) _______________________________________________ help-gplusplus mailing list help-gplusplus@gnu.org http://lists.gnu.org/mailman/listinfo/help-gplusplus