diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2015-12-20 05:39:39 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2015-12-20 05:39:39 +0200 |
commit | db3f10e93b5c4c804d9f2127ab7697fb0638cc2f (patch) | |
tree | 8f5f265e3ee3c8eb5a54f2328cd97a18797f836a | |
parent | 382101ae725a0f6b97f0ecdba1023d7b63cd3157 (diff) |
Detect Clang that pretends to be very old GCC
On FreeBSD, Clang 3.7 says it is GCC 4.2. Go figure.
-rw-r--r-- | odb/details/config.hxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/odb/details/config.hxx b/odb/details/config.hxx index c8f6239..c36b163 100644 --- a/odb/details/config.hxx +++ b/odb/details/config.hxx @@ -27,7 +27,9 @@ # include <odb/details/config.h> # if defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L # define ODB_CXX11 -# ifdef __GNUC__ +# ifdef __clang__ // Pretends to be a really old __GNUC__ on some platforms. +# define ODB_CXX11_NULLPTR +# elif defined(__GNUC__) # if (__GNUC__ == 4 && __GNUC_MINOR__ >= 6) || __GNUC__ > 4 # define ODB_CXX11_NULLPTR # endif |