From 93234a5581f36f6b5f7c7a2d93270454c3f282f4 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Sun, 6 Apr 2025 21:06:53 +0200 Subject: [PATCH] Fix potential conflict of __attribute__((noreturn)) If is included first, then noreturn is defined to _Noreturn, and then __attribute__((noreturn)) will end up being __attribute__((_Noreturn)), which would not be recognized and might result in a compiler warning. To avoid this, use the alternative spelling __attribute__((__noreturn__)) instead. This is supported by the same compiler versions. --- perl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/perl.h b/perl.h index ee3b850af20d..935954d179bb 100644 --- a/perl.h +++ b/perl.h @@ -438,7 +438,7 @@ Now a no-op. # define __attribute__nonnull__(a) __attribute__((nonnull(a))) #endif #ifdef HASATTRIBUTE_NORETURN -# define __attribute__noreturn__ __attribute__((noreturn)) +# define __attribute__noreturn__ __attribute__((__noreturn__)) #endif #ifdef HASATTRIBUTE_PURE # define __attribute__pure__ __attribute__((pure))