From 2c8d96d86f5c389a88a87e01f03b2f214b7d1143 Mon Sep 17 00:00:00 2001 From: Edward Nolan Date: Wed, 9 Jul 2025 19:43:51 -0400 Subject: [PATCH] Don't set C++ standard version in the CMake Doing so violates the [CMAKE.PASSIVE_PROJECT] requirement of the Beman Standard: https://github.com/bemanproject/beman/blob/main/docs/BEMAN_STANDARD.md#cmakepassive_projects Due to this setting, all the CI jobs were running with C++26 set, making the C++20 jobs spuriously pass. This commit removes them. It also changes the C++ standard version used by the presets from C++20 to C++23. --- .github/workflows/ci_tests.yml | 10 +++++----- CMakePresets.json | 2 +- src/beman/execution/CMakeLists.txt | 5 ----- 3 files changed, 6 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci_tests.yml b/.github/workflows/ci_tests.yml index 0d7963a7..7c0b9871 100644 --- a/.github/workflows/ci_tests.yml +++ b/.github/workflows/ci_tests.yml @@ -46,14 +46,14 @@ jobs: } ] }, - { "cxxversions": ["c++23", "c++20"], + { "cxxversions": ["c++23"], "tests": [{ "stdlibs": ["libstdc++"], "tests": ["Release.Default"]}] } ] }, { "versions": ["14", "13"], "tests": [ - { "cxxversions": ["c++26", "c++23", "c++20"], + { "cxxversions": ["c++26", "c++23"], "tests": [{ "stdlibs": ["libstdc++"], "tests": ["Release.Default"]}] } ] @@ -72,7 +72,7 @@ jobs: } ] }, - { "cxxversions": ["c++23", "c++20"], + { "cxxversions": ["c++23"], "tests": [ {"stdlibs": ["libstdc++", "libc++"], "tests": ["Release.Default"]} ] @@ -81,7 +81,7 @@ jobs: }, { "versions": ["19"], "tests": [ - { "cxxversions": ["c++26", "c++23", "c++20"], + { "cxxversions": ["c++26", "c++23"], "tests": [ {"stdlibs": ["libstdc++", "libc++"], "tests": ["Release.Default"]} ] @@ -90,7 +90,7 @@ jobs: }, { "versions": ["18", "17"], "tests": [ - { "cxxversions": ["c++26", "c++23", "c++20"], + { "cxxversions": ["c++26", "c++23"], "tests": [{"stdlibs": ["libc++"], "tests": ["Release.Default"]}] } ] diff --git a/CMakePresets.json b/CMakePresets.json index 483e1a34..bd35911e 100644 --- a/CMakePresets.json +++ b/CMakePresets.json @@ -7,7 +7,7 @@ "generator": "Ninja", "binaryDir": "${sourceDir}/build/${presetName}", "cacheVariables": { - "CMAKE_CXX_STANDARD": "20", + "CMAKE_CXX_STANDARD": "23", "CMAKE_EXPORT_COMPILE_COMMANDS": "ON", "CMAKE_PROJECT_TOP_LEVEL_INCLUDES": "./infra/cmake/use-fetch-content.cmake" } diff --git a/src/beman/execution/CMakeLists.txt b/src/beman/execution/CMakeLists.txt index 1b89b44f..8482469e 100644 --- a/src/beman/execution/CMakeLists.txt +++ b/src/beman/execution/CMakeLists.txt @@ -210,11 +210,6 @@ source_group("Header Files\\detail" FILES ${DETAIL_HEADER_FILES}) set_target_properties(${TARGET_NAME} PROPERTIES VERIFY_INTERFACE_HEADER_SETS ON) -target_compile_features(${TARGET_NAME} PUBLIC - "$<$:cxx_std_26>" - "$<$>:cxx_std_23>" -) - if(NOT BEMAN_EXECUTION_ENABLE_INSTALL OR CMAKE_SKIP_INSTALL_RULES) return() endif()