diff --git a/doc/macro_reference.qbk b/doc/macro_reference.qbk index 8e67f7c8..af7cbdc7 100644 --- a/doc/macro_reference.qbk +++ b/doc/macro_reference.qbk @@ -881,6 +881,10 @@ If `BOOST_NO_CXX11_NOEXCEPT` is not defined (i.e. C++11 compliant compilers) the `` ] ]] +[[`BOOST_FINAL`][ +If `BOOST_NO_CXX11_FINAL` is not defined (i.e. C++11 compliant compilers), expands to `final` keyword, +otherwise expands to nothing. +]] [[`BOOST_MSVC_ENABLE_2012_NOV_CTP`][ For Microsoft Visual C++ 2012, enable the C++11 features supplied by the November 2012 Community Technology Preview. These features are not automatically diff --git a/include/boost/config/detail/suffix.hpp b/include/boost/config/detail/suffix.hpp index 86f6081e..1d6691f8 100644 --- a/include/boost/config/detail/suffix.hpp +++ b/include/boost/config/detail/suffix.hpp @@ -943,6 +943,14 @@ namespace std{ using ::type_info; } // ------------------ End of deprecated macros for 1.51 --------------------------- +// +// Helper macro for marking types and methods final +// +#if !defined(BOOST_NO_CXX11_FINAL) +# define BOOST_FINAL final +#else +# define BOOST_FINAL +#endif // // Helper macros BOOST_NOEXCEPT, BOOST_NOEXCEPT_IF, BOOST_NOEXCEPT_EXPR