stdio: Suppress -Wformat only for gcc in tst-sprintf-errno.c

Since Clang doesn't support

DIAG_IGNORE_NEEDS_COMMENT (11, "-Wformat=");

and for unknown reasons, it doesn't warn the %#m specifier, suppress
-Wformat only for gcc in tst-sprintf-errno.c.

Co-Authored-By: H.J. Lu <hjl.tools@gmail.com>
Reviewed-by: Sam James <sam@gentoo.org>
This commit is contained in:
Adhemerval Zanella 2024-12-23 05:11:59 +08:00 committed by H.J. Lu
parent a2b0ff98a0
commit 309225af54

View File

@ -24,7 +24,7 @@
/* GCC does not yet know about the %#m specifier. */
DIAG_PUSH_NEEDS_COMMENT;
DIAG_IGNORE_NEEDS_COMMENT (11, "-Wformat=");
DIAG_IGNORE_NEEDS_COMMENT_GCC (11, "-Wformat=");
static int
do_test (void)