aboutsummaryrefslogtreecommitdiff
path: root/math/test-tgmath-ret.c
diff options
context:
space:
mode:
Diffstat (limited to 'math/test-tgmath-ret.c')
-rw-r--r--math/test-tgmath-ret.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/math/test-tgmath-ret.c b/math/test-tgmath-ret.c
index 36dc132..a3342f6 100644
--- a/math/test-tgmath-ret.c
+++ b/math/test-tgmath-ret.c
@@ -1,5 +1,5 @@
/* Test compilation of tgmath macros.
- Copyright (C) 2003-2024 Free Software Foundation, Inc.
+ Copyright (C) 2003-2025 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -21,13 +21,19 @@
#include <tgmath.h>
#include <stdint.h>
#include <stdio.h>
+#include <libc-diag.h>
+/* clang warns the global variables are not needed and will not be emitted.
+ However they are used on the CHECK_RET_* macros. */
+DIAG_PUSH_NEEDS_COMMENT_CLANG;
+DIAG_IGNORE_NEEDS_COMMENT_CLANG (13, "-Wunneeded-internal-declaration");
static float fx;
static double dx;
static long double lx;
static int rm = FP_INT_UPWARD;
static unsigned int width = 64;
static int errors = 0;
+DIAG_POP_NEEDS_COMMENT_CLANG;
static void
our_error (const char *c)