From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2181) id 20BAF3858427; Mon, 4 Apr 2022 11:46:40 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 20BAF3858427 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Jonathan Wakely To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc r11-9761] libstdc++: Add suggestion to std::uncaught_exception() warning X-Act-Checkin: gcc X-Git-Author: Jonathan Wakely X-Git-Refname: refs/heads/releases/gcc-11 X-Git-Oldrev: fe76adc667b4e521705540b30b68ab988c6abbec X-Git-Newrev: ab0efe756e22d3124a3614d2907f5df6d269b675 Message-Id: <20220404114640.20BAF3858427@sourceware.org> Date: Mon, 4 Apr 2022 11:46:40 +0000 (GMT) X-BeenThere: libstdc++-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libstdc++-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 Apr 2022 11:46:40 -0000 https://gcc.gnu.org/g:ab0efe756e22d3124a3614d2907f5df6d269b675 commit r11-9761-gab0efe756e22d3124a3614d2907f5df6d269b675 Author: Jonathan Wakely Date: Thu Feb 3 13:17:05 2022 +0000 libstdc++: Add suggestion to std::uncaught_exception() warning We should use the SUGGEST macro for std::uncaught_exception() deprecation warnings. libstdc++-v3/ChangeLog: * include/bits/allocator.h: Qualify std::allocator_traits in deprecated warnings. * libsupc++/exception (uncaught_exception): Add suggestion to deprecated warning. (cherry picked from commit 27ba40559ccb887458009a34f710d4a22af85156) Diff: --- libstdc++-v3/include/bits/allocator.h | 4 ++-- libstdc++-v3/libsupc++/exception | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/libstdc++-v3/include/bits/allocator.h b/libstdc++-v3/include/bits/allocator.h index a6883c6758a..e0c0a4b56bf 100644 --- a/libstdc++-v3/include/bits/allocator.h +++ b/libstdc++-v3/include/bits/allocator.h @@ -92,7 +92,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION using propagate_on_container_move_assignment = true_type; using is_always_equal - _GLIBCXX20_DEPRECATED_SUGGEST("allocator_traits::is_always_equal") + _GLIBCXX20_DEPRECATED_SUGGEST("std::allocator_traits::is_always_equal") = true_type; #if __cplusplus >= 202002L @@ -146,7 +146,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION using propagate_on_container_move_assignment = true_type; using is_always_equal - _GLIBCXX20_DEPRECATED_SUGGEST("allocator_traits::is_always_equal") + _GLIBCXX20_DEPRECATED_SUGGEST("std::allocator_traits::is_always_equal") = true_type; #endif diff --git a/libstdc++-v3/libsupc++/exception b/libstdc++-v3/libsupc++/exception index a023e22ea89..61ed3373360 100644 --- a/libstdc++-v3/libsupc++/exception +++ b/libstdc++-v3/libsupc++/exception @@ -105,7 +105,7 @@ namespace std * %exception can result in a call of 1terminate()` * (15.5.1).' */ - _GLIBCXX17_DEPRECATED + _GLIBCXX17_DEPRECATED_SUGGEST("std::uncaught_exceptions()") bool uncaught_exception() _GLIBCXX_USE_NOEXCEPT __attribute__ ((__pure__)); #if __cplusplus >= 201703L || !defined(__STRICT_ANSI__) // c++17 or gnu++98