]> Savannah Git Hosting - gnulib.git/commitdiff
verify: port to pedantic gcc -std=c99
authorPaul Eggert <eggert@cs.ucla.edu>
Wed, 20 Apr 2022 01:02:43 +0000 (18:02 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Wed, 20 Apr 2022 01:24:23 +0000 (18:24 -0700)
* lib/verify.h (_GL_VERIFY): If we lack both _Static_assert and
static_assert, suppress -Wnexted-externs.

ChangeLog
lib/verify.h

index 9bab736be4a6671d210cfb88234fded1dee1fb6c..c2509b8387fd1493ddbe6048f9994a158644560b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2022-04-19  Paul Eggert  <eggert@cs.ucla.edu>
 
+       verify: port to pedantic gcc -std=c99
+       * lib/verify.h (_GL_VERIFY): If we lack both _Static_assert and
+       static_assert, suppress -Wnexted-externs.
+
        gettime-res: add tests
        * modules/gettime-res-tests, tests/test-gettime-res.c: New files.
 
index c2d2a5667065fbd961170e041aad7d5efbfb4167..c5c63ae97c6c8cae264a888c3b4c419cb01955d1 100644 (file)
@@ -215,6 +215,9 @@ template <int w>
 # define _GL_VERIFY(R, DIAGNOSTIC, ...)                                \
     extern int (*_GL_GENSYM (_gl_verify_function) (void))             \
       [_GL_VERIFY_TRUE (R, DIAGNOSTIC)]
+# if 4 < __GNUC__ + (6 <= __GNUC_MINOR__)
+#  pragma GCC diagnostic ignored "-Wnested-externs"
+# endif
 #endif
 
 /* _GL_STATIC_ASSERT_H is defined if this code is copied into assert.h.  */