brintos

brintos / llvm-project-archived public Read only

0
0
Text · 10.0 KiB · ceb338d Raw
330 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// <tuple>13 14// Test the feature test macros defined by <tuple>15 16// clang-format off17 18#include <tuple>19#include "test_macros.h"20 21#if TEST_STD_VER < 1422 23#  ifdef __cpp_lib_apply24#    error "__cpp_lib_apply should not be defined before c++17"25#  endif26 27#  ifdef __cpp_lib_constexpr_tuple28#    error "__cpp_lib_constexpr_tuple should not be defined before c++20"29#  endif30 31#  ifdef __cpp_lib_constrained_equality32#    error "__cpp_lib_constrained_equality should not be defined before c++26"33#  endif34 35#  ifdef __cpp_lib_make_from_tuple36#    error "__cpp_lib_make_from_tuple should not be defined before c++17"37#  endif38 39#  ifdef __cpp_lib_ranges_zip40#    error "__cpp_lib_ranges_zip should not be defined before c++23"41#  endif42 43#  ifdef __cpp_lib_tuple_element_t44#    error "__cpp_lib_tuple_element_t should not be defined before c++14"45#  endif46 47#  ifdef __cpp_lib_tuple_like48#    error "__cpp_lib_tuple_like should not be defined before c++23"49#  endif50 51#  ifdef __cpp_lib_tuples_by_type52#    error "__cpp_lib_tuples_by_type should not be defined before c++14"53#  endif54 55#elif TEST_STD_VER == 1456 57#  ifdef __cpp_lib_apply58#    error "__cpp_lib_apply should not be defined before c++17"59#  endif60 61#  ifdef __cpp_lib_constexpr_tuple62#    error "__cpp_lib_constexpr_tuple should not be defined before c++20"63#  endif64 65#  ifdef __cpp_lib_constrained_equality66#    error "__cpp_lib_constrained_equality should not be defined before c++26"67#  endif68 69#  ifdef __cpp_lib_make_from_tuple70#    error "__cpp_lib_make_from_tuple should not be defined before c++17"71#  endif72 73#  ifdef __cpp_lib_ranges_zip74#    error "__cpp_lib_ranges_zip should not be defined before c++23"75#  endif76 77#  ifndef __cpp_lib_tuple_element_t78#    error "__cpp_lib_tuple_element_t should be defined in c++14"79#  endif80#  if __cpp_lib_tuple_element_t != 201402L81#    error "__cpp_lib_tuple_element_t should have the value 201402L in c++14"82#  endif83 84#  ifdef __cpp_lib_tuple_like85#    error "__cpp_lib_tuple_like should not be defined before c++23"86#  endif87 88#  ifndef __cpp_lib_tuples_by_type89#    error "__cpp_lib_tuples_by_type should be defined in c++14"90#  endif91#  if __cpp_lib_tuples_by_type != 201304L92#    error "__cpp_lib_tuples_by_type should have the value 201304L in c++14"93#  endif94 95#elif TEST_STD_VER == 1796 97#  ifndef __cpp_lib_apply98#    error "__cpp_lib_apply should be defined in c++17"99#  endif100#  if __cpp_lib_apply != 201603L101#    error "__cpp_lib_apply should have the value 201603L in c++17"102#  endif103 104#  ifdef __cpp_lib_constexpr_tuple105#    error "__cpp_lib_constexpr_tuple should not be defined before c++20"106#  endif107 108#  ifdef __cpp_lib_constrained_equality109#    error "__cpp_lib_constrained_equality should not be defined before c++26"110#  endif111 112#  ifndef __cpp_lib_make_from_tuple113#    error "__cpp_lib_make_from_tuple should be defined in c++17"114#  endif115#  if __cpp_lib_make_from_tuple != 201606L116#    error "__cpp_lib_make_from_tuple should have the value 201606L in c++17"117#  endif118 119#  ifdef __cpp_lib_ranges_zip120#    error "__cpp_lib_ranges_zip should not be defined before c++23"121#  endif122 123#  ifndef __cpp_lib_tuple_element_t124#    error "__cpp_lib_tuple_element_t should be defined in c++17"125#  endif126#  if __cpp_lib_tuple_element_t != 201402L127#    error "__cpp_lib_tuple_element_t should have the value 201402L in c++17"128#  endif129 130#  ifdef __cpp_lib_tuple_like131#    error "__cpp_lib_tuple_like should not be defined before c++23"132#  endif133 134#  ifndef __cpp_lib_tuples_by_type135#    error "__cpp_lib_tuples_by_type should be defined in c++17"136#  endif137#  if __cpp_lib_tuples_by_type != 201304L138#    error "__cpp_lib_tuples_by_type should have the value 201304L in c++17"139#  endif140 141#elif TEST_STD_VER == 20142 143#  ifndef __cpp_lib_apply144#    error "__cpp_lib_apply should be defined in c++20"145#  endif146#  if __cpp_lib_apply != 201603L147#    error "__cpp_lib_apply should have the value 201603L in c++20"148#  endif149 150#  ifndef __cpp_lib_constexpr_tuple151#    error "__cpp_lib_constexpr_tuple should be defined in c++20"152#  endif153#  if __cpp_lib_constexpr_tuple != 201811L154#    error "__cpp_lib_constexpr_tuple should have the value 201811L in c++20"155#  endif156 157#  ifdef __cpp_lib_constrained_equality158#    error "__cpp_lib_constrained_equality should not be defined before c++26"159#  endif160 161#  ifndef __cpp_lib_make_from_tuple162#    error "__cpp_lib_make_from_tuple should be defined in c++20"163#  endif164#  if __cpp_lib_make_from_tuple != 201606L165#    error "__cpp_lib_make_from_tuple should have the value 201606L in c++20"166#  endif167 168#  ifdef __cpp_lib_ranges_zip169#    error "__cpp_lib_ranges_zip should not be defined before c++23"170#  endif171 172#  ifndef __cpp_lib_tuple_element_t173#    error "__cpp_lib_tuple_element_t should be defined in c++20"174#  endif175#  if __cpp_lib_tuple_element_t != 201402L176#    error "__cpp_lib_tuple_element_t should have the value 201402L in c++20"177#  endif178 179#  ifdef __cpp_lib_tuple_like180#    error "__cpp_lib_tuple_like should not be defined before c++23"181#  endif182 183#  ifndef __cpp_lib_tuples_by_type184#    error "__cpp_lib_tuples_by_type should be defined in c++20"185#  endif186#  if __cpp_lib_tuples_by_type != 201304L187#    error "__cpp_lib_tuples_by_type should have the value 201304L in c++20"188#  endif189 190#elif TEST_STD_VER == 23191 192#  ifndef __cpp_lib_apply193#    error "__cpp_lib_apply should be defined in c++23"194#  endif195#  if __cpp_lib_apply != 201603L196#    error "__cpp_lib_apply should have the value 201603L in c++23"197#  endif198 199#  ifndef __cpp_lib_constexpr_tuple200#    error "__cpp_lib_constexpr_tuple should be defined in c++23"201#  endif202#  if __cpp_lib_constexpr_tuple != 201811L203#    error "__cpp_lib_constexpr_tuple should have the value 201811L in c++23"204#  endif205 206#  ifdef __cpp_lib_constrained_equality207#    error "__cpp_lib_constrained_equality should not be defined before c++26"208#  endif209 210#  ifndef __cpp_lib_make_from_tuple211#    error "__cpp_lib_make_from_tuple should be defined in c++23"212#  endif213#  if __cpp_lib_make_from_tuple != 201606L214#    error "__cpp_lib_make_from_tuple should have the value 201606L in c++23"215#  endif216 217#  if !defined(_LIBCPP_VERSION)218#    ifndef __cpp_lib_ranges_zip219#      error "__cpp_lib_ranges_zip should be defined in c++23"220#    endif221#    if __cpp_lib_ranges_zip != 202110L222#      error "__cpp_lib_ranges_zip should have the value 202110L in c++23"223#    endif224#  else225#    ifdef __cpp_lib_ranges_zip226#      error "__cpp_lib_ranges_zip should not be defined because it is unimplemented in libc++!"227#    endif228#  endif229 230#  ifndef __cpp_lib_tuple_element_t231#    error "__cpp_lib_tuple_element_t should be defined in c++23"232#  endif233#  if __cpp_lib_tuple_element_t != 201402L234#    error "__cpp_lib_tuple_element_t should have the value 201402L in c++23"235#  endif236 237#  if !defined(_LIBCPP_VERSION)238#    ifndef __cpp_lib_tuple_like239#      error "__cpp_lib_tuple_like should be defined in c++23"240#    endif241#    if __cpp_lib_tuple_like != 202207L242#      error "__cpp_lib_tuple_like should have the value 202207L in c++23"243#    endif244#  else245#    ifdef __cpp_lib_tuple_like246#      error "__cpp_lib_tuple_like should not be defined because it is unimplemented in libc++!"247#    endif248#  endif249 250#  ifndef __cpp_lib_tuples_by_type251#    error "__cpp_lib_tuples_by_type should be defined in c++23"252#  endif253#  if __cpp_lib_tuples_by_type != 201304L254#    error "__cpp_lib_tuples_by_type should have the value 201304L in c++23"255#  endif256 257#elif TEST_STD_VER > 23258 259#  ifndef __cpp_lib_apply260#    error "__cpp_lib_apply should be defined in c++26"261#  endif262#  if __cpp_lib_apply != 201603L263#    error "__cpp_lib_apply should have the value 201603L in c++26"264#  endif265 266#  ifndef __cpp_lib_constexpr_tuple267#    error "__cpp_lib_constexpr_tuple should be defined in c++26"268#  endif269#  if __cpp_lib_constexpr_tuple != 201811L270#    error "__cpp_lib_constexpr_tuple should have the value 201811L in c++26"271#  endif272 273#  ifndef __cpp_lib_constrained_equality274#    error "__cpp_lib_constrained_equality should be defined in c++26"275#  endif276#  if __cpp_lib_constrained_equality != 202411L277#    error "__cpp_lib_constrained_equality should have the value 202411L in c++26"278#  endif279 280#  ifndef __cpp_lib_make_from_tuple281#    error "__cpp_lib_make_from_tuple should be defined in c++26"282#  endif283#  if __cpp_lib_make_from_tuple != 201606L284#    error "__cpp_lib_make_from_tuple should have the value 201606L in c++26"285#  endif286 287#  if !defined(_LIBCPP_VERSION)288#    ifndef __cpp_lib_ranges_zip289#      error "__cpp_lib_ranges_zip should be defined in c++26"290#    endif291#    if __cpp_lib_ranges_zip != 202110L292#      error "__cpp_lib_ranges_zip should have the value 202110L in c++26"293#    endif294#  else295#    ifdef __cpp_lib_ranges_zip296#      error "__cpp_lib_ranges_zip should not be defined because it is unimplemented in libc++!"297#    endif298#  endif299 300#  ifndef __cpp_lib_tuple_element_t301#    error "__cpp_lib_tuple_element_t should be defined in c++26"302#  endif303#  if __cpp_lib_tuple_element_t != 201402L304#    error "__cpp_lib_tuple_element_t should have the value 201402L in c++26"305#  endif306 307#  if !defined(_LIBCPP_VERSION)308#    ifndef __cpp_lib_tuple_like309#      error "__cpp_lib_tuple_like should be defined in c++26"310#    endif311#    if __cpp_lib_tuple_like != 202311L312#      error "__cpp_lib_tuple_like should have the value 202311L in c++26"313#    endif314#  else315#    ifdef __cpp_lib_tuple_like316#      error "__cpp_lib_tuple_like should not be defined because it is unimplemented in libc++!"317#    endif318#  endif319 320#  ifndef __cpp_lib_tuples_by_type321#    error "__cpp_lib_tuples_by_type should be defined in c++26"322#  endif323#  if __cpp_lib_tuples_by_type != 201304L324#    error "__cpp_lib_tuples_by_type should have the value 201304L in c++26"325#  endif326 327#endif // TEST_STD_VER > 23328 329// clang-format on330