mirror of
https://github.com/boostorg/utility.git
synced 2025-07-30 12:57:31 +02:00
Revert "Ref: Remove obsolete MSVC version check."
This reverts commit adf57817ec
.
Conflicts:
include/boost/ref.hpp
This commit is contained in:
@ -34,8 +34,16 @@ template<class T> class reference_wrapper
|
|||||||
public:
|
public:
|
||||||
typedef T type;
|
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)) {}
|
BOOST_FORCEINLINE explicit reference_wrapper(T& t): t_(boost::addressof(t)) {}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
BOOST_FORCEINLINE operator T& () const { return *t_; }
|
BOOST_FORCEINLINE operator T& () const { return *t_; }
|
||||||
|
|
||||||
BOOST_FORCEINLINE T& get() const { return *t_; }
|
BOOST_FORCEINLINE T& get() const { return *t_; }
|
||||||
|
Reference in New Issue
Block a user