>     $ gcc --version | sed 1q
>     gcc (GCC) 15.1.1 20250425 (Red Hat 15.1.1-1)

And the error is reproducible also with other compiler versions.

gcc 13:

In file included from ../../gllib/string-desc.c:20:
../config.h:1361:28: error: attributes should be specified before the 
declarator in a function definition
 1361 | # define _GL_EXTERN_INLINE extern inline
      |                            ^~~~~~
../../gllib/string-desc.c:23:31: note: in expansion of macro ‘_GL_EXTERN_INLINE’
   23 | #define GL_STRING_DESC_INLINE _GL_EXTERN_INLINE
      |                               ^~~~~~~~~~~~~~~~~
../../gllib/string-desc.h:319:1: note: in expansion of macro 
‘GL_STRING_DESC_INLINE’
  319 | GL_STRING_DESC_INLINE char
      | ^~~~~~~~~~~~~~~~~~~~~
make[4]: *** [Makefile:2911: string-desc.o] Error 1


clang:

../../gltests/../gllib/string-desc.h:321:3: warning: GCC does not allow 
'__nonnull__' attribute in this position on a function definition [-Wgcc-compat]
  321 |   _GL_ATTRIBUTE_NONNULL ((2))
      |   ^
../config.h:2536:55: note: expanded from macro '_GL_ATTRIBUTE_NONNULL'
 2536 | #  define _GL_ATTRIBUTE_NONNULL(args) __attribute__ ((__nonnull__ args))
      |                                                       ^




Reply via email to