summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorscivision <scivision@users.noreply.github.com>2024-05-12 02:24:05 (GMT)
committerBrad King <brad.king@kitware.com>2024-05-13 15:02:04 (GMT)
commit80d4bd5370235c03a27296e91de5ec7e24cc2ebc (patch)
tree1d0d0f6425985b31e10067c6173988e078b9526a /Modules
parent40513f6a90c0ede0cce54da7f345f6c22b26e8ab (diff)
downloadCMake-80d4bd5370235c03a27296e91de5ec7e24cc2ebc.zip
CMake-80d4bd5370235c03a27296e91de5ec7e24cc2ebc.tar.gz
CMake-80d4bd5370235c03a27296e91de5ec7e24cc2ebc.tar.bz2
IntelLLVM: Record C++26 support
Diffstat (limited to 'Modules')
-rw-r--r--Modules/Compiler/IntelLLVM-CXX.cmake25
1 files changed, 23 insertions, 2 deletions
diff --git a/Modules/Compiler/IntelLLVM-CXX.cmake b/Modules/Compiler/IntelLLVM-CXX.cmake
index 989a1d4..45e5d66 100644
--- a/Modules/Compiler/IntelLLVM-CXX.cmake
+++ b/Modules/Compiler/IntelLLVM-CXX.cmake
@@ -49,11 +49,21 @@ if(NOT "x${CMAKE_CXX_SIMULATE_ID}" STREQUAL "xMSVC")
set(CMAKE_CXX_STANDARD_LATEST 20)
- if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 2021.2.0)
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 2024.0.0)
+ set(CMAKE_CXX23_STANDARD_COMPILE_OPTION "-std=c++23")
+ set(CMAKE_CXX23_EXTENSION_COMPILE_OPTION "-std=gnu++23")
+ set(CMAKE_CXX_STANDARD_LATEST 23)
+ elseif(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 2021.2.0)
set(CMAKE_CXX23_STANDARD_COMPILE_OPTION "-std=c++2b")
set(CMAKE_CXX23_EXTENSION_COMPILE_OPTION "-std=gnu++2b")
set(CMAKE_CXX_STANDARD_LATEST 23)
endif()
+
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 2024.0.0)
+ set(CMAKE_CXX26_STANDARD_COMPILE_OPTION "-std=c++26")
+ set(CMAKE_CXX26_EXTENSION_COMPILE_OPTION "-std=gnu++26")
+ set(CMAKE_CXX_STANDARD_LATEST 26)
+ endif()
else()
set(CMAKE_CXX98_STANDARD_COMPILE_OPTION "")
set(CMAKE_CXX98_EXTENSION_COMPILE_OPTION "")
@@ -72,11 +82,22 @@ else()
set(CMAKE_CXX_STANDARD_LATEST 20)
- if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 2021.2.0)
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 2024.0.0)
+ set(CMAKE_CXX23_STANDARD_COMPILE_OPTION "-Qstd=c++23")
+ set(CMAKE_CXX23_EXTENSION_COMPILE_OPTION "-Qstd=c++23")
+ set(CMAKE_CXX_STANDARD_LATEST 23)
+ elseif(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 2021.2.0)
set(CMAKE_CXX23_STANDARD_COMPILE_OPTION "-Qstd:c++2b")
set(CMAKE_CXX23_EXTENSION_COMPILE_OPTION "-Qstd:c++2b")
set(CMAKE_CXX_STANDARD_LATEST 23)
endif()
+
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 2024.0.0)
+ set(CMAKE_CXX26_STANDARD_COMPILE_OPTION "-Qstd=c++26")
+ set(CMAKE_CXX26_EXTENSION_COMPILE_OPTION "-Qstd=c++26")
+ set(CMAKE_CXX_STANDARD_LATEST 26)
+ endif()
+
endif()
__compiler_check_default_language_standard(CXX 2020 14)