diff --git a/config.compat b/config.compat index f835561d..5ac7cfe1 100644 --- a/config.compat +++ b/config.compat @@ -920,9 +920,12 @@ NAMESPACE_END # define CRYPTOPP_NO_THROW #endif // CRYPTOPP_CXX11_NOEXCEPT +// http://stackoverflow.com/a/13867690/608639 #if defined(CRYPTOPP_CXX11_CONSTEXPR) +# define CRYPTOPP_STATIC_CONSTEXPR static constexpr # define CRYPTOPP_CONSTEXPR constexpr #else +# define CRYPTOPP_STATIC_CONSTEXPR static const # define CRYPTOPP_CONSTEXPR #endif // CRYPTOPP_CXX11_CONSTEXPR diff --git a/config.h b/config.h index 140e2e31..a72583fc 100644 --- a/config.h +++ b/config.h @@ -920,9 +920,12 @@ NAMESPACE_END # define CRYPTOPP_NO_THROW #endif // CRYPTOPP_CXX11_NOEXCEPT +// http://stackoverflow.com/a/13867690/608639 #if defined(CRYPTOPP_CXX11_CONSTEXPR) +# define CRYPTOPP_STATIC_CONSTEXPR static constexpr # define CRYPTOPP_CONSTEXPR constexpr #else +# define CRYPTOPP_STATIC_CONSTEXPR static const # define CRYPTOPP_CONSTEXPR #endif // CRYPTOPP_CXX11_CONSTEXPR