public inbox for libstdc++@gcc.gnu.org
 help / color / mirror / Atom feed
From: Marcus Haehnel <marcus.haehnel@kernkonzept.com>
To: libstdc++@gcc.gnu.org
Cc: Marcus Haehnel <marcus.haehnel@kernkonzept.com>
Subject: [PATCH] libstdc++: use updated type for __unexpected_handler
Date: Fri, 15 Dec 2023 16:43:28 +0100	[thread overview]
Message-ID: <20231215154331.12114-1-marcus.haehnel@kernkonzept.com> (raw)

Commit f4130a3eb545ab1aaf3ecb44f3d06b43e3751e04 changed the type of
__expected_handler in libsupc++/unwind-cxx.h to be a
std::terminate_handler to avoid a deprecated warning. However, the
definition in eh_unex_handler.cc still used the old type
(std::unexpected_handler) and thus causes a warning when compiling
libstdc++ with -Wdeprecated-declarations (which is the default, for
example, for clang).

Adapt the definition to match the declaration.

libstdc++-v3/ChangeLog:
* libsupc++/eh_unex_handler: Adjust definition type to declaration.
---
 libstdc++-v3/libsupc++/eh_unex_handler.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libstdc++-v3/libsupc++/eh_unex_handler.cc b/libstdc++-v3/libsupc++/eh_unex_handler.cc
index 0b7fa34e082..879585ee513 100644
--- a/libstdc++-v3/libsupc++/eh_unex_handler.cc
+++ b/libstdc++-v3/libsupc++/eh_unex_handler.cc
@@ -25,5 +25,5 @@
 #include "unwind-cxx.h"
 
 /* The current installed user handler.  */
-std::unexpected_handler __cxxabiv1::__unexpected_handler = std::terminate;
+std::terminate_handler __cxxabiv1::__unexpected_handler = std::terminate;
 
-- 
2.42.0


             reply	other threads:[~2023-12-15 15:42 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-15 15:43 Marcus Haehnel [this message]
2024-01-11 16:03 ` Fwd: " Marcus Hähnel
2024-01-11 16:10   ` Jonathan Wakely

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231215154331.12114-1-marcus.haehnel@kernkonzept.com \
    --to=marcus.haehnel@kernkonzept.com \
    --cc=libstdc++@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).