From 02877516757c0b54fe69297324b54082621bea91 Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Wed, 26 Jan 2022 17:22:42 +0200 Subject: [PATCH] Make location member of wrapexcept_location non-const, to enable assignment --- include/boost/throw_exception.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/boost/throw_exception.hpp b/include/boost/throw_exception.hpp index 3ef17c3..37d9352 100644 --- a/include/boost/throw_exception.hpp +++ b/include/boost/throw_exception.hpp @@ -69,9 +69,9 @@ template struct wrapexcept_add_base struct wrapexcept_location { wrapexcept_location() {} - explicit wrapexcept_location( boost::source_location const& loc ): loc_( loc ) {} + explicit wrapexcept_location( boost::source_location const& loc ): location_( loc ) {} - boost::source_location const loc_; + boost::source_location location_; }; } // namespace detail @@ -265,7 +265,7 @@ template boost::source_location get_throw_location( E const& e ) #else detail::wrapexcept_location const* p = dynamic_cast< detail::wrapexcept_location const* >( &e ); - return p? p->loc_: boost::source_location(); + return p? p->location_: boost::source_location(); #endif }