diff --git a/include/boost/none.hpp b/include/boost/none.hpp index a37c45c..b5df214 100644 --- a/include/boost/none.hpp +++ b/include/boost/none.hpp @@ -13,6 +13,7 @@ #ifndef BOOST_NONE_17SEP2003_HPP #define BOOST_NONE_17SEP2003_HPP +#include "boost/config.hpp" #include "boost/none_t.hpp" // NOTE: Borland users have to include this header outside any precompiled headers @@ -23,7 +24,7 @@ namespace boost { #ifdef BOOST_OPTIONAL_USE_OLD_DEFINITION_OF_NONE -none_t const none = (static_cast(0)) ; +BOOST_INLINE_VARIABLE none_t const none = (static_cast(0)) ; #elif defined BOOST_OPTIONAL_USE_SINGLETON_DEFINITION_OF_NONE @@ -35,7 +36,7 @@ namespace detail { namespace optional_detail { { static const T instance; }; - + template const T none_instance::instance = T(); // global, but because 'tis a template, no cpp file required @@ -49,7 +50,7 @@ namespace { #else -const none_t none ((none_t::init_tag())); +BOOST_INLINE_VARIABLE const none_t none ((none_t::init_tag())); #endif // older definitions