[PATCH 1/5] posix: Sync regex code with gnulib

Bruno Haible bruno@clisp.org
Tue Jan 19 15:43:10 GMT 2021


Adhemerval Zanella wrote:
> -# if (__GNUC__ >= 7) || (__clang_major__ >= 10)
> +# if (__GNUC__ >= 7) || (defined __clang_major__ &&__clang_major__ >= 10)

I would write it as:

+# if (__GNUC__ >= 7) || (defined __clang__ && __clang_major__ >= 10)

because 'defined __clang__' is the widely known way to test for a clang
(or derivate) compiler.

Bruno



More information about the Libc-alpha mailing list