From 0cb1b7276d0dad50678ac80a416e748e3d0a6ff2 Mon Sep 17 00:00:00 2001 From: Eric Botcazou Date: Mon, 25 May 2020 10:53:00 +0200 Subject: [PATCH] [Ada] Disable warning about unsafe use of __builtin_frame_address gcc/ada/ * tracebak.c [generic implementation]: Add pragma GCC diagnostic to disable warning about __builtin_frame_address. --- gcc/ada/tracebak.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gcc/ada/tracebak.c b/gcc/ada/tracebak.c index 43dc438a1d6..d643cfc50db 100644 --- a/gcc/ada/tracebak.c +++ b/gcc/ada/tracebak.c @@ -690,6 +690,9 @@ __gnat_backtrace (void ** traceback __attribute__((unused)), #elif defined (USE_GENERIC_UNWINDER) +/* No warning since the cases where FRAME_LEVEL > 0 are known to work. */ +#pragma GCC diagnostic ignored "-Wframe-address" + #ifndef CURRENT_STACK_FRAME # define CURRENT_STACK_FRAME ({ char __csf; &__csf; }) #endif -- 2.30.2