From 79d9d9f5141ae77d20aaa963dd89839516ad4ffb Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Wed, 11 Dec 2013 00:46:10 +0200 Subject: [PATCH] Revert "Ref: Remove obsolete MSVC version check." This reverts commit adf57817ec09cb8edd6032a30da6daec3edbe23f. Conflicts: include/boost/ref.hpp --- include/boost/ref.hpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/include/boost/ref.hpp b/include/boost/ref.hpp index e31b167..8169149 100644 --- a/include/boost/ref.hpp +++ b/include/boost/ref.hpp @@ -34,8 +34,16 @@ template class reference_wrapper public: typedef T type; +#if defined( BOOST_MSVC ) && BOOST_WORKAROUND( BOOST_MSVC, < 1300 ) + + explicit reference_wrapper(T& t): t_(&t) {} + +#else + BOOST_FORCEINLINE explicit reference_wrapper(T& t): t_(boost::addressof(t)) {} +#endif + BOOST_FORCEINLINE operator T& () const { return *t_; } BOOST_FORCEINLINE T& get() const { return *t_; }