* lib/mini-gmp-gnulib.c: Ignore -Wanalyzer-write-to-const in
versions of GCC that support that option, as mini-gmp.c itself
doesn’t worry about pacifying that warning.
---
 ChangeLog             | 9 ++++++++-
 lib/mini-gmp-gnulib.c | 4 ++++
 2 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 1f449e1c92..8c3db3c465 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2026-10-28  Paul Eggert  <[email protected]>
+
+       libgmp-mpz: Pacify more gcc warnings
+       * lib/mini-gmp-gnulib.c: Ignore -Wanalyzer-write-to-const in
+       versions of GCC that support that option, as mini-gmp.c itself
+       doesn’t worry about pacifying that warning.
+
 2026-10-27  Kamila Szewczyk <[email protected]>
 
        announce-gen: Perl list buglet, cksum sha3 usage.
@@ -2774,7 +2781,7 @@
 
        libgmp-mpz: pacify -Wuseless-cast
        * lib/mini-gmp-gnulib.c: Ignore -Wuseless-cast, as we
-       don’t want top change lib/mini-gmp.c.
+       don’t want to change lib/mini-gmp.c.
 
 2026-05-26  Bruno Haible  <[email protected]>
 
diff --git a/lib/mini-gmp-gnulib.c b/lib/mini-gmp-gnulib.c
index d3bb998c4b..dc5f695ce4 100644
--- a/lib/mini-gmp-gnulib.c
+++ b/lib/mini-gmp-gnulib.c
@@ -39,6 +39,10 @@
 # pragma GCC diagnostic ignored "-Wsuggest-attribute=malloc"
 #endif
 
+#if _GL_GNUC_PREREQ (11, 0)
+# pragma GCC diagnostic ignored "-Wanalyzer-write-to-const"
+#endif
+
 #if _GL_GNUC_PREREQ (14, 0)
 # pragma GCC diagnostic ignored "-Wuseless-cast"
 #endif
-- 
2.56.0


Reply via email to