* lib/intprops-internal.h: Ignore -Wuseless-cast.
* lib/vasnprintf.c: Ignore -Wuseless-cast.
2026-05-07 Paul Eggert <eggert@cs.ucla.edu>
+ Pacify -Wuseless cast with a pragma
+ * lib/intprops-internal.h: Ignore -Wuseless-cast.
+ * lib/vasnprintf.c: Ignore -Wuseless-cast.
+
Pacify GCC 16 -Wuseless-cast by omitting casts
* lib/obstack.in.h (obstack_free): Omit unnecessary cast.
* lib/printf-args.c (PRINTF_FETCHARGS): Omit unnecessary casts.
# pragma GCC diagnostic ignored "-Wtype-limits"
#endif
+/* This file uses many casts that might provoke -Wuseless-cast. */
+#if 16 <= __GNUC__
+# pragma GCC diagnostic ignored "-Wuseless-cast"
+#endif
+
/* Return a value with the common real type of E and V and the value of V.
Do not evaluate E. */
#define _GL_INT_CONVERT(e, v) ((1 ? 0 : (e)) + (v))
# pragma GCC diagnostic ignored "-Wanalyzer-null-argument"
#endif
+/* This code has a lot of parameterized pointer casts that may be no-ops. */
+#if _GL_GNUC_PREREQ (16, 0) || 11 <= __clang_major__
+# pragma GCC diagnostic ignored "-Wuseless-cast"
+#endif
+
#include <alloca.h>
/* Specification. */