diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2023-02-21 11:10:00 +0100 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2023-05-09 20:00:18 +0200 |
commit | e2b0721c33d0df57c6a596b18ae98644575c51f9 (patch) | |
tree | 8a8e16e3c3e26314722c2b5f51f4c72ab57b1942 /include/cppunit | |
parent | 5f9aab1993016720db1d7008ed190b0a96293190 (diff) | |
download | cppunit-master.tar.gz |
...which happens to define __GNUC__=4, __GNUC_MINOR__=2. (See also
<https://git.libreoffice.org/core/+/9a23239b710e44754e4a28643420c9ba91552645%5E%21>
"external/cppunit: Don't mis-apply GCC < 4.6 workaround for Clang". This change
requires <https://gerrit.libreoffice.org/c/cppunit/+/147383> "Use snprintf
instead of sprintf" to avoid deprecation warnings on macOS, which had originally
been hidden by the mis-applied #pragma.)
Change-Id: I4fcb38a79766238862795ba4019638862e65b041
Reviewed-on: https://gerrit.libreoffice.org/c/cppunit/+/147384
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Diffstat (limited to 'include/cppunit')
-rw-r--r-- | include/cppunit/TestAssert.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/cppunit/TestAssert.h b/include/cppunit/TestAssert.h index 19a8ae5..de97f21 100644 --- a/include/cppunit/TestAssert.h +++ b/include/cppunit/TestAssert.h @@ -11,7 +11,8 @@ // Work around "passing 'T' chooses 'int' over 'unsigned int'" warnings when T // is an enum type: -#if defined __GNUC__ && (__GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 6)) +#if defined __GNUC__ && (__GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 6)) \ + && !defined __clang__ #pragma GCC system_header #endif |