--- On Tue, 2/9/08, Peter Dimov
From: Peter Dimov
Subject: Re: [Boost-users] [bind] [lambda] making lambda::bind work To: boost-users@lists.boost.org Date: Tuesday, 2 September, 2008, 12:31 PM Peter Barker: In my program auto_ptr is being used in boost::bind via boost::ref and it works fine. Does this work by design, or coincidence? I couldn't see boost::reference_wrapper and boost::addressof handling std::auto_ptr specially.
It works by design. boost::mem_fn uses get_pointer, and get_pointer for auto_ptr returns .get().
For lambda::bind, you may want to try using *ll::var(p) instead; lambda::bind has no special support for smart pointers.
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
I'll take a look at boost::mem_fn and get_pointer. You've also just saved me from posting up a question about lambda::bind and smart pointers. Really appreciate your help and thanks for boost::bind()!