Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r66367 - sandbox/function/boost/function
From: dsaritz_at_[hidden]
Date: 2010-11-02 18:04:48


Author: psiha
Date: 2010-11-02 18:04:46 EDT (Tue, 02 Nov 2010)
New Revision: 66367
URL: http://svn.boost.org/trac/boost/changeset/66367

Log:
Added a MSVC 10 workaround.
Text files modified:
   sandbox/function/boost/function/function_template.hpp | 8 +++++++-
   1 files changed, 7 insertions(+), 1 deletions(-)

Modified: sandbox/function/boost/function/function_template.hpp
==============================================================================
--- sandbox/function/boost/function/function_template.hpp (original)
+++ sandbox/function/boost/function/function_template.hpp 2010-11-02 18:04:46 EDT (Tue, 02 Nov 2010)
@@ -608,7 +608,13 @@
     void do_assign( FunctionObj const & f, Allocator const a )
     {
         typedef typename detail::function::get_function_tag<FunctionObj>::type tag;
- dispatch_assign<direct, FunctionObj>( f, a, tag() );
+ // Implementation note:
+ // If the FunctionObj template parameter is (re)specified explicitly
+ // in the call to dispatch_assign MSVC 10 generates totally bogus code
+ // (causing access-violation crashes) when function pointers are
+ // assigned using the syntax without the ampersand.
+ // (02.11.2010.) (Domagoj Saric)
+ dispatch_assign<direct>( f, a, tag() );
     }
 
     template <bool direct, typename FunctionObj>


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk