diff options
author | Bruno Haible <bruno@clisp.org> | 2023-02-09 18:37:55 +0100 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2023-02-09 18:37:55 +0100 |
commit | 885c890cb6f9c675ad8e962366958752cc0d00dc (patch) | |
tree | 514395149780ed769fc7bd7578bddd47f0785af6 /m4 | |
parent | 962a577b7685e0aa938b8241460c12484ae725c3 (diff) | |
download | gnulib-885c890cb6f9c675ad8e962366958752cc0d00dc.tar.gz |
Fix compilation errors in C++ mode on macOS 12.5.
* m4/gnulib-common.m4 (gl_COMMON_BODY): Don't define
_GL_ATTRIBUTE_MAYBE_UNUSED to [[__maybe_unused__]] if the compiler is
an Apple variant of clang.
Diffstat (limited to 'm4')
-rw-r--r-- | m4/gnulib-common.m4 | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/m4/gnulib-common.m4 b/m4/gnulib-common.m4 index c0181abdc5..1e6748ed8c 100644 --- a/m4/gnulib-common.m4 +++ b/m4/gnulib-common.m4 @@ -1,4 +1,4 @@ -# gnulib-common.m4 serial 80 +# gnulib-common.m4 serial 81 dnl Copyright (C) 2007-2023 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -356,7 +356,7 @@ AC_DEFUN([gl_COMMON_BODY], [ [[__maybe_unused__]] nevertheless produces a warning. */ #ifndef _GL_ATTRIBUTE_MAYBE_UNUSED # if defined __clang__ && defined __cplusplus -# if __clang_major__ >= 10 +# if !defined __apple_build_version__ && __clang_major__ >= 10 # define _GL_ATTRIBUTE_MAYBE_UNUSED [[__maybe_unused__]] # endif # elif defined __has_c_attribute |