From: Jonathan Wakely Date: Wed, 18 Sep 2024 14:41:05 +0000 (+0100) Subject: libstdc++: Silence -Wattributes warning in exception_ptr X-Git-Tag: releases/gcc-14.3.0~758 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4b7a1dbd3c2427c118d32657e27c8611c5f8da52;p=thirdparty%2Fgcc.git libstdc++: Silence -Wattributes warning in exception_ptr libstdc++-v3/ChangeLog: * libsupc++/exception_ptr.h (__exception_ptr::_M_safe_bool_dummy): Remove __attribute__((const)) from function returning void. (cherry picked from commit 164c1b1f812da5d1e00fc10a415e80f7c508efcb) --- diff --git a/libstdc++-v3/libsupc++/exception_ptr.h b/libstdc++-v3/libsupc++/exception_ptr.h index 7c234ce0bf20..ee977a8a6eac 100644 --- a/libstdc++-v3/libsupc++/exception_ptr.h +++ b/libstdc++-v3/libsupc++/exception_ptr.h @@ -151,8 +151,7 @@ namespace std _GLIBCXX_VISIBILITY(default) #ifdef _GLIBCXX_EH_PTR_COMPAT // Retained for compatibility with CXXABI_1.3. - void _M_safe_bool_dummy() _GLIBCXX_USE_NOEXCEPT - __attribute__ ((__const__)); + void _M_safe_bool_dummy() _GLIBCXX_USE_NOEXCEPT; bool operator!() const _GLIBCXX_USE_NOEXCEPT __attribute__ ((__pure__)); operator __safe_bool() const _GLIBCXX_USE_NOEXCEPT;