Debian Codegraph @

libstdc++-v3/testsuite/20_util/shared_ptr/creation/version.cc

raw
1 // { dg-do preprocess { target c++20 } }
2 // { dg-require-effective-target hosted }
3 // { dg-add-options no_pch }
4
5 // C++20 20.11.3.7 shared_ptr Creation [util.smartptr.shared.create]
6
7 #include <version>
8
9 #ifndef __cpp_lib_shared_ptr_arrays
10 # error "Feature-test macro for make_shared arrays missing in <version>"
11 #elif __cpp_lib_shared_ptr_arrays < 201707L
12 # error "Feature-test macro for make_shared arrays has wrong value in <version>"
13 #endif
14
15 #ifndef __cpp_lib_smart_ptr_for_overwrite
16 # error "Feature-test macro for make_shared_for_overwrite missing in <version>"
17 #elif __cpp_lib_smart_ptr_for_overwrite < 202002L
18 # error "Feature-test macro for make_shared_for_overwrite has wrong value in <version>"
19 #endif