diff --git a/doc/empty_value.qbk b/doc/empty_value.qbk index ce0d906..8ab874c 100644 --- a/doc/empty_value.qbk +++ b/doc/empty_value.qbk @@ -92,9 +92,9 @@ public: template explicit empty_value(empty_init_t, Args&&... args); - const T& get() const; + const T& get() const noexcept; - T& get(); + T& get() noexcept; }; } /* boost */ @@ -127,8 +127,8 @@ public: [section Member functions] [variablelist -[[`const T& get() const;`][Returns the value]] -[[`T& get();`][Returns the value]]] +[[`const T& get() const noexcept;`][Returns the value]] +[[`T& get() noexcept;`][Returns the value]]] [endsect] diff --git a/include/boost/core/empty_value.hpp b/include/boost/core/empty_value.hpp index 60ca36f..9265f05 100644 --- a/include/boost/core/empty_value.hpp +++ b/include/boost/core/empty_value.hpp @@ -42,7 +42,8 @@ struct empty_init_t { }; namespace empty_ { -template::value> +template::value> class empty_value { public: typedef T type; @@ -53,22 +54,22 @@ public: empty_value() { } #endif - empty_value(empty_init_t) + empty_value(boost::empty_init_t) : value_() { } #if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) template - explicit empty_value(empty_init_t, Args&&... args) + explicit empty_value(boost::empty_init_t, Args&&... args) : value_(std::forward(args)...) { } #else template - empty_value(empty_init_t, U&& value) + empty_value(boost::empty_init_t, U&& value) : value_(std::forward(value)) { } #endif #else template - empty_value(empty_init_t, const U& value) + empty_value(boost::empty_init_t, const U& value) : value_(value) { } #endif @@ -97,22 +98,22 @@ public: empty_value() { } #endif - empty_value(empty_init_t) + empty_value(boost::empty_init_t) : T() { } #if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) template - explicit empty_value(empty_init_t, Args&&... args) + explicit empty_value(boost::empty_init_t, Args&&... args) : T(std::forward(args)...) { } #else template - empty_value(empty_init_t, U&& value) + empty_value(boost::empty_init_t, U&& value) : T(std::forward(value)) { } #endif #else template - empty_value(empty_init_t, const U& value) + empty_value(boost::empty_init_t, const U& value) : T(value) { } #endif