[PATCH 4/8] stdio: Fix tst-vfprintf-user-type on clang
Adhemerval Zanella
adhemerval.zanella@linaro.org
Wed Dec 17 17:51:50 GMT 2025
The pointer alias comparison will be optimized away by the compiler,
and gcc and clang will evaluate it differently (clang evaluates it
as false, while gcc evaluates it as true).
---
stdio-common/tst-vfprintf-user-type.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/stdio-common/tst-vfprintf-user-type.c b/stdio-common/tst-vfprintf-user-type.c
index 3fc98b30f1..41ae8a45c1 100644
--- a/stdio-common/tst-vfprintf-user-type.c
+++ b/stdio-common/tst-vfprintf-user-type.c
@@ -183,7 +183,6 @@ do_test (void)
#else
extern int asprintf_alias (char **, const char *, ...) __asm__ ("asprintf");
#endif
- TEST_VERIFY (asprintf_alias == asprintf);
char *str = NULL;
TEST_VERIFY (asprintf_alias (&str, "[[%P]]", 123L, 456.0) >= 0);
TEST_COMPARE_STRING (str, "[[(123, 456.000000)]]");
--
2.43.0
More information about the Libc-alpha
mailing list