From 8b25bdb38e4391f42f324fb346e6ac68eb617893 Mon Sep 17 00:00:00 2001 From: Axel Huebl Date: Wed, 28 Oct 2020 17:12:42 -0700 Subject: [PATCH] GCC<=4.9: Exceptions GCC 4.8 and 4.9 support exceptions, but are not detected as such. This adds exception support for those compilers. Detection taken from `nlohmann/json`. --- include/mpark/config.hpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/mpark/config.hpp b/include/mpark/config.hpp index f85ffb55c..5bc9acb95 100644 --- a/include/mpark/config.hpp +++ b/include/mpark/config.hpp @@ -64,7 +64,8 @@ #endif #if __has_feature(cxx_exceptions) || defined(__cpp_exceptions) || \ - (defined(_MSC_VER) && defined(_CPPUNWIND)) + (defined(_MSC_VER) && defined(_CPPUNWIND)) || \ + defined(__EXCEPTIONS) #define MPARK_EXCEPTIONS #endif