1//===----------------------------------------------------------------------===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
9// WARNING: This test was generated by generate_feature_test_macro_components.py
10// and should not be edited manually.
11
12// UNSUPPORTED: no-localization
13
14// <regex>
15
16// Test the feature test macros defined by <regex>
17
18// clang-format off
19
20#include <regex>
21#include "test_macros.h"
22
23#if TEST_STD_VER < 14
24
25# ifdef __cpp_lib_nonmember_container_access
26# error "__cpp_lib_nonmember_container_access should not be defined before c++17"
27# endif
28
29#elif TEST_STD_VER == 14
30
31# ifdef __cpp_lib_nonmember_container_access
32# error "__cpp_lib_nonmember_container_access should not be defined before c++17"
33# endif
34
35#elif TEST_STD_VER == 17
36
37# ifndef __cpp_lib_nonmember_container_access
38# error "__cpp_lib_nonmember_container_access should be defined in c++17"
39# endif
40# if __cpp_lib_nonmember_container_access != 201411L
41# error "__cpp_lib_nonmember_container_access should have the value 201411L in c++17"
42# endif
43
44#elif TEST_STD_VER == 20
45
46# ifndef __cpp_lib_nonmember_container_access
47# error "__cpp_lib_nonmember_container_access should be defined in c++20"
48# endif
49# if __cpp_lib_nonmember_container_access != 201411L
50# error "__cpp_lib_nonmember_container_access should have the value 201411L in c++20"
51# endif
52
53#elif TEST_STD_VER == 23
54
55# ifndef __cpp_lib_nonmember_container_access
56# error "__cpp_lib_nonmember_container_access should be defined in c++23"
57# endif
58# if __cpp_lib_nonmember_container_access != 201411L
59# error "__cpp_lib_nonmember_container_access should have the value 201411L in c++23"
60# endif
61
62#elif TEST_STD_VER > 23
63
64# ifndef __cpp_lib_nonmember_container_access
65# error "__cpp_lib_nonmember_container_access should be defined in c++26"
66# endif
67# if __cpp_lib_nonmember_container_access != 201411L
68# error "__cpp_lib_nonmember_container_access should have the value 201411L in c++26"
69# endif
70
71#endif // TEST_STD_VER > 23
72
73// clang-format on
74
75

source code of libcxx/test/std/language.support/support.limits/support.limits.general/regex.version.compile.pass.cpp