mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-17 03:02:24 +01:00
restrict nullptr detection to gcc 4 (closes #526)
The old detection logic here assumed that all versions of gcc >= 5 would provide nullptr and `std::nullptr_t`; this is only true in gcc >= 5 when the standard is explicitly set (e.g. `std=c++11`), and other detection logic handles that. This change allows Catch-using programs to compile with gcc >= 5, when using the default (C++98) standard.
This commit is contained in:
parent
d758428fe2
commit
0394905325
@ -66,7 +66,7 @@
|
||||
// GCC
|
||||
#ifdef __GNUC__
|
||||
|
||||
#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6 && defined(__GXX_EXPERIMENTAL_CXX0X__) )
|
||||
#if __GNUC__ == 4 && __GNUC_MINOR__ >= 6 && defined(__GXX_EXPERIMENTAL_CXX0X__)
|
||||
# define CATCH_INTERNAL_CONFIG_CPP11_NULLPTR
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user