Disable addressof for r-values when possible

This commit is contained in:
Glen Fernandes committed 2017-04-23 02:04:54 -04:00
1 parent 46545326d8
commit dc6003e26f
4 files changed
+40 -4

No files matched your search

+10
View File
@@ -262,4 +262,14 @@ addressof(T& o) BOOST_NOEXCEPT
} /* boost */
#endif
#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) && \
!defined(BOOST_NO_CXX11_DELETED_FUNCTIONS)
namespace boost {
template<class T>
const T* addressof(const T&&) = delete;
} /* boost */
#endif
#endif