Boost logo

Boost :

Subject: [boost] [function] bug
From: Okko Willeboordse (okko.willeboordse_at_[hidden])
Date: 2009-02-10 15:42:27


Applies for 1.37 and 1.38.
Using VS2008, SDK 6.1

See ...\function\function_template.hpp

945 #if !defined(BOOST_NO_EXCEPTIONS)
946 try {
947 #endif
948 if (!f.empty()) {
949 this->vtable = f.vtable;
950 f.vtable->manager(f.functor, this->functor,
951 boost::detail::function::move_functor_tag);
952 f.vtable = 0;
953 #if !defined(BOOST_NO_EXCEPTIONS)
954 } else {
955 clear();
956 }
957 } catch (...) {
958 vtable = 0;
959 throw;
960 }
961 #endif
962 }

Line
953 #if !defined(BOOST_NO_EXCEPTIONS)
must be moved 3 lines down like;

945 #if !defined(BOOST_NO_EXCEPTIONS)
946 try {
947 #endif
948 if (!f.empty()) {
949 this->vtable = f.vtable;
950 f.vtable->manager(f.functor, this->functor,
951 boost::detail::function::move_functor_tag);
952 f.vtable = 0;
953 } else {
954 clear();
955 }
956 #if !defined(BOOST_NO_EXCEPTIONS)
957 } catch (...) {
958 vtable = 0;
959 throw;
960 }
961 #endif
962 }


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk