mirror of
https://github.com/Kitware/CMake.git
synced 2025-12-31 02:39:48 -06:00
Features: Add special case to disable relaxed constexpr for Intel 18
Intel compilers define `__cpp_constexpr` to `200704` even in C++14 mode. This indicates that the `cxx_relaxed_constexpr` feature is not available. However, Intel 17 and above document support for it. In commit v3.8.0~9^2 (Features: Update features for Intel C++ 17.0.2 on UNIX, 2017-03-31) we added a special check for this case. Intel 17 and 19 work. However, Intel 18 does not seem to work and fails our test case. Add a special case to disable the feature for Intel 18.
This commit is contained in:
@@ -24,7 +24,7 @@ set(DETECT_CXX14 "((__cplusplus >= 201300L) || ((__cplusplus == 201103L) && !def
|
||||
unset(DETECT_BUGGY_ICC15)
|
||||
|
||||
set(Intel17_CXX14 "__INTEL_COMPILER >= 1700 && ${DETECT_CXX14}")
|
||||
set(_cmake_feature_test_cxx_relaxed_constexpr "__cpp_constexpr >= 201304 || (${Intel17_CXX14} && !defined(_MSC_VER))")
|
||||
set(_cmake_feature_test_cxx_relaxed_constexpr "__cpp_constexpr >= 201304 || (${Intel17_CXX14} && __INTEL_COMPILER != 1800 && !defined(_MSC_VER))")
|
||||
|
||||
set(Intel16_CXX14 "__INTEL_COMPILER >= 1600 && ${DETECT_CXX14}")
|
||||
set(_cmake_feature_test_cxx_aggregate_default_initializers "${Intel16_CXX14}")
|
||||
|
||||
Reference in New Issue
Block a user