summaryrefslogtreecommitdiff
path: root/libstdc++-v3/testsuite/21_strings/basic_string/numeric_conversions/version.cc
blob: 669becc36f14ea4b319a0fde07cfe0beb444067c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// { dg-do compile }
// { dg-add-options no_pch }

#include <version>

#if __cplusplus > 202302L

#ifndef __cpp_lib_to_string
# error "Feature-test macro for std::to_string missing in <string>"
#elif __cpp_lib_to_string != 202306L
# error "Feature-test macro for std::to_string has wrong value in <string>"
#endif

#else

#ifdef __cpp_lib_to_string
# error "__cpp_lib_to_string should not be defined for C++23"
#endif

#endif