From: Jonathan Wakely Date: Thu, 16 Sep 2021 13:14:38 +0000 (+0100) Subject: libstdc++: Add noexcept to std::nullopt_t constructor X-Git-Tag: basepoints/gcc-13~4719 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cbe705a2f749c98a5f803afeb207e175b4c9a3c3;p=thirdparty%2Fgcc.git libstdc++: Add noexcept to std::nullopt_t constructor Signed-off-by: Jonathan Wakely libstdc++-v3/ChangeLog: * include/std/optional (nullptr_t): Make constructor noexcept. --- diff --git a/libstdc++-v3/include/std/optional b/libstdc++-v3/include/std/optional index b8ab75107572..b6ebe12b3e19 100644 --- a/libstdc++-v3/include/std/optional +++ b/libstdc++-v3/include/std/optional @@ -70,7 +70,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION enum class _Construct { _Token }; // Must be constexpr for nullopt_t to be literal. - explicit constexpr nullopt_t(_Construct) { } + explicit constexpr nullopt_t(_Construct) noexcept { } }; /// Tag to disengage optional objects.