We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ad5c639 commit c71ac3eCopy full SHA for c71ac3e
examples/CMakeLists.txt
@@ -2,6 +2,11 @@
2
3
set(ALL_EXAMPLES scope_example unique_resource unique_resource-file)
4
5
+# module tests will only compile with gcc15 or clang20 and above
6
+if(CMAKE_CXX_SCAN_FOR_MODULES AND CMAKE_CXX_STANDARD GREATER 20)
7
+ list(APPEND ALL_EXAMPLES scope-module)
8
+endif()
9
+
10
message("Examples to be built: ${ALL_EXAMPLES}")
11
12
foreach(example ${ALL_EXAMPLES})
examples/scope-module.cpp
@@ -15,7 +15,12 @@
15
// destroy noisy
16
// scope exit: true success: true fail: false
17
18
+#ifdef HAS_MODULE_STD
19
import std;
20
+#else
21
+#include <print>
22
+#endif
23
24
import beman.scope;
25
26
// clang-format off
0 commit comments