diff --git a/include/boost/ref.hpp b/include/boost/ref.hpp index b35fb0f..29f8930 100644 --- a/include/boost/ref.hpp +++ b/include/boost/ref.hpp @@ -39,12 +39,18 @@ private: reference_wrapper & operator= (reference_wrapper const &); }; -template inline reference_wrapper ref(T & t) +#if defined(__BORLANDC__) && (__BORLANDC__ <= 0x551) +#define BOOST_REF_CONST +#else +#define BOOST_REF_CONST const +#endif + +template inline reference_wrapper BOOST_REF_CONST ref(T & t) { return reference_wrapper(t); } -template inline reference_wrapper cref(T const & t) +template inline reference_wrapper BOOST_REF_CONST cref(T const & t) { return reference_wrapper(t); }