diff options
author | Jörg Frings-Fürst <debian@jff.email> | 2025-03-22 18:00:25 +0100 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff.email> | 2025-03-22 18:00:25 +0100 |
commit | 0737819efdd0bae112d16d874cac7e747e43cd08 (patch) | |
tree | 98a9ac84f7f347ae530c14852c68870682f3d04c /lib/warn-on-use.h | |
parent | 163a663518f33bab48b28431972e580b366b4d49 (diff) | |
parent | e670957a8693f860cf7d77fed4ce6b4b056a8083 (diff) |
Merge branch 'release/debian/1.3-1'debian/1.3-1
Diffstat (limited to 'lib/warn-on-use.h')
-rw-r--r-- | lib/warn-on-use.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/warn-on-use.h b/lib/warn-on-use.h index 701013a0..73c43971 100644 --- a/lib/warn-on-use.h +++ b/lib/warn-on-use.h @@ -85,7 +85,7 @@ */ #ifndef _GL_WARN_ON_USE -# if 4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__) +# if (4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__)) && !defined __clang__ /* A compiler attribute is available in gcc versions 4.3.0 and later. */ # define _GL_WARN_ON_USE(function, message) \ _GL_WARN_EXTERN_C __typeof__ (function) function __attribute__ ((__warning__ (message))) @@ -98,7 +98,7 @@ _GL_WARN_EXTERN_C __typeof__ (function) function \ __attribute__ ((__diagnose_if__ (1, message, "warning"))) # define _GL_WARN_ON_USE_ATTRIBUTE(message) \ __attribute__ ((__diagnose_if__ (1, message, "warning"))) -# elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING +# elif (__GNUC__ >= 3 || defined __clang__) && GNULIB_STRICT_CHECKING /* Verify the existence of the function. */ # define _GL_WARN_ON_USE(function, message) \ _GL_WARN_EXTERN_C __typeof__ (function) function @@ -121,7 +121,7 @@ _GL_WARN_EXTERN_C int _gl_warn_on_use # define _GL_WARN_ON_USE_CXX(function,rettype_gcc,rettype_clang,parameters_and_attributes,msg) \ _GL_WARN_ON_USE (function, msg) # else -# if 4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__) +# if (4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__)) && !defined __clang__ /* A compiler attribute is available in gcc versions 4.3.0 and later. */ # define _GL_WARN_ON_USE_CXX(function,rettype_gcc,rettype_clang,parameters_and_attributes,msg) \ extern rettype_gcc function parameters_and_attributes \ @@ -131,7 +131,7 @@ extern rettype_gcc function parameters_and_attributes \ # define _GL_WARN_ON_USE_CXX(function,rettype_gcc,rettype_clang,parameters_and_attributes,msg) \ extern rettype_clang function parameters_and_attributes \ __attribute__ ((__diagnose_if__ (1, msg, "warning"))) -# elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING +# elif (__GNUC__ >= 3 || defined __clang__) && GNULIB_STRICT_CHECKING /* Verify the existence of the function. */ # define _GL_WARN_ON_USE_CXX(function,rettype_gcc,rettype_clang,parameters_and_attributes,msg) \ extern rettype_gcc function parameters_and_attributes |