69 lines · cpp
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-exception6//7//===----------------------------------------------------------------------===//8 9// WARNING: This test was generated by generate_feature_test_macro_components.py10// and should not be edited manually.11 12// <concepts>13 14// Test the feature test macros defined by <concepts>15 16// clang-format off17 18#include <concepts>19#include "test_macros.h"20 21#if TEST_STD_VER < 1422 23# ifdef __cpp_lib_concepts24# error "__cpp_lib_concepts should not be defined before c++20"25# endif26 27#elif TEST_STD_VER == 1428 29# ifdef __cpp_lib_concepts30# error "__cpp_lib_concepts should not be defined before c++20"31# endif32 33#elif TEST_STD_VER == 1734 35# ifdef __cpp_lib_concepts36# error "__cpp_lib_concepts should not be defined before c++20"37# endif38 39#elif TEST_STD_VER == 2040 41# ifndef __cpp_lib_concepts42# error "__cpp_lib_concepts should be defined in c++20"43# endif44# if __cpp_lib_concepts != 202002L45# error "__cpp_lib_concepts should have the value 202002L in c++20"46# endif47 48#elif TEST_STD_VER == 2349 50# ifndef __cpp_lib_concepts51# error "__cpp_lib_concepts should be defined in c++23"52# endif53# if __cpp_lib_concepts != 202002L54# error "__cpp_lib_concepts should have the value 202002L in c++23"55# endif56 57#elif TEST_STD_VER > 2358 59# ifndef __cpp_lib_concepts60# error "__cpp_lib_concepts should be defined in c++26"61# endif62# if __cpp_lib_concepts != 202002L63# error "__cpp_lib_concepts should have the value 202002L in c++26"64# endif65 66#endif // TEST_STD_VER > 2367 68// clang-format on69