When defining BOOST_STL_INTERFACES_USE_DEDUCED_THIS=1, require C++23 mode for

the cases where __cpp_explicit_this_parameter is not defined, but the compiler
is known to support it.  Obviously, even if those compiler support it, it's
not available in older C++ versions.

Fixes #72.
Related to https://github.com/boostorg/stl_interfaces/pull/68
This commit is contained in:
Zach Laine
2024-11-10 12:43:48 -06:00
parent f89646cddf
commit cefbd3014a

View File

@@ -20,10 +20,11 @@
#define BOOST_STL_INTERFACES_USE_CONCEPTS 0
#endif
#if (defined(__cpp_explicit_this_parameter) || \
(defined(_MSC_VER) && _MSC_VER >= 1941) || \
(defined(BOOST_CLANG_VERSION) && BOOST_CLANG_VERSION >= 190000)) && \
BOOST_STL_INTERFACES_USE_CONCEPTS && \
#if ( \
defined(__cpp_explicit_this_parameter) || \
(defined(_MSC_VER) && _MSC_VER >= 1941) || \
(defined(BOOST_CLANG_VERSION) && BOOST_CLANG_VERSION >= 190000)) && \
BOOST_STL_INTERFACES_USE_CONCEPTS && (202002L < __cplusplus) && \
!defined(BOOST_STL_INTERFACES_DISABLE_DEDUCED_THIS)
#define BOOST_STL_INTERFACES_USE_DEDUCED_THIS 1
#else