xref: /netbsd-src/external/gpl3/gcc.old/dist/libstdc++-v3/include/std/version (revision 4c3eb207d36f67d31994830c0a694161fc1ca39b)
1627f7eb2Smrg// -*- C++ -*- Libstdc++ version details header.
2627f7eb2Smrg
3*4c3eb207Smrg// Copyright (C) 2018-2020 Free Software Foundation, Inc.
4627f7eb2Smrg//
5627f7eb2Smrg// This file is part of the GNU ISO C++ Library.  This library is free
6627f7eb2Smrg// software; you can redistribute it and/or modify it under the
7627f7eb2Smrg// terms of the GNU General Public License as published by the
8627f7eb2Smrg// Free Software Foundation; either version 3, or (at your option)
9627f7eb2Smrg// any later version.
10627f7eb2Smrg
11627f7eb2Smrg// This library is distributed in the hope that it will be useful,
12627f7eb2Smrg// but WITHOUT ANY WARRANTY; without even the implied warranty of
13627f7eb2Smrg// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14627f7eb2Smrg// GNU General Public License for more details.
15627f7eb2Smrg
16627f7eb2Smrg// Under Section 7 of GPL version 3, you are granted additional
17627f7eb2Smrg// permissions described in the GCC Runtime Library Exception, version
18627f7eb2Smrg// 3.1, as published by the Free Software Foundation.
19627f7eb2Smrg
20627f7eb2Smrg// You should have received a copy of the GNU General Public License and
21627f7eb2Smrg// a copy of the GCC Runtime Library Exception along with this program;
22627f7eb2Smrg// see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
23627f7eb2Smrg// <http://www.gnu.org/licenses/>.
24627f7eb2Smrg
25627f7eb2Smrg/** @file version
26627f7eb2Smrg *  This is a Standard C++ Library file.  You should @c \#include this file
27627f7eb2Smrg *  in your programs, rather than any of the @a *.h implementation files.
28627f7eb2Smrg */
29627f7eb2Smrg
30627f7eb2Smrg#ifndef _GLIBCXX_VERSION_INCLUDED
31627f7eb2Smrg#define _GLIBCXX_VERSION_INCLUDED
32627f7eb2Smrg
33627f7eb2Smrg#pragma GCC system_header
34627f7eb2Smrg
35627f7eb2Smrg#include <bits/c++config.h>
36627f7eb2Smrg
37627f7eb2Smrg// c++03
38*4c3eb207Smrg#if _GLIBCXX_HOSTED
39627f7eb2Smrg# define __cpp_lib_incomplete_container_elements 201505
40*4c3eb207Smrg#endif
41627f7eb2Smrg
42627f7eb2Smrg#if !defined(__STRICT_ANSI__)
43627f7eb2Smrg// gnu++03
44627f7eb2Smrg# define __cpp_lib_uncaught_exceptions 201411L
45627f7eb2Smrg#endif
46627f7eb2Smrg
47627f7eb2Smrg#if __cplusplus >= 201103L
48627f7eb2Smrg// c++11
49627f7eb2Smrg#define __cpp_lib_is_null_pointer 201309
50627f7eb2Smrg#define __cpp_lib_result_of_sfinae 201210
51*4c3eb207Smrg
52*4c3eb207Smrg#if _GLIBCXX_HOSTED
53*4c3eb207Smrg# define __cpp_lib_allocator_traits_is_always_equal 201411
54627f7eb2Smrg# define __cpp_lib_shared_ptr_arrays 201611L
55*4c3eb207Smrg#endif
56627f7eb2Smrg
57627f7eb2Smrg#if !defined(__STRICT_ANSI__)
58627f7eb2Smrg// gnu++11
59627f7eb2Smrg# define __cpp_lib_is_swappable 201603
60627f7eb2Smrg# define __cpp_lib_void_t 201411
61*4c3eb207Smrg# if _GLIBCXX_HOSTED
62*4c3eb207Smrg#  define __cpp_lib_enable_shared_from_this 201603
63*4c3eb207Smrg# endif
64627f7eb2Smrg#endif
65627f7eb2Smrg
66627f7eb2Smrg// For C++11 and later we support ISO/IEC 29124 Mathematical Special Functions
67627f7eb2Smrg#define __STDCPP_MATH_SPEC_FUNCS__ 201003L
68627f7eb2Smrg
69627f7eb2Smrg#if __cplusplus >= 201402L
70627f7eb2Smrg// c++14
71*4c3eb207Smrg#if __cpp_impl_coroutine
72*4c3eb207Smrg# define __cpp_lib_coroutine 201902L
73*4c3eb207Smrg#endif
74*4c3eb207Smrg#define __cpp_lib_integral_constant_callable 201304
75*4c3eb207Smrg#define __cpp_lib_is_final 201402L
76*4c3eb207Smrg#define __cpp_lib_transformation_trait_aliases 201304
77*4c3eb207Smrg
78*4c3eb207Smrg#if _GLIBCXX_HOSTED
79627f7eb2Smrg# define __cpp_lib_chrono_udls 201304
80627f7eb2Smrg# define __cpp_lib_complex_udls 201309
81627f7eb2Smrg# define __cpp_lib_exchange_function 201304
82627f7eb2Smrg# define __cpp_lib_generic_associative_lookup 201304
83627f7eb2Smrg# define __cpp_lib_integer_sequence 201304
84627f7eb2Smrg# define __cpp_lib_make_reverse_iterator 201402
85627f7eb2Smrg# define __cpp_lib_make_unique 201304
86627f7eb2Smrg# ifndef _GLIBCXX_DEBUG // PR libstdc++/70303
87627f7eb2Smrg#  define __cpp_lib_null_iterators 201304L
88627f7eb2Smrg# endif
89627f7eb2Smrg# define __cpp_lib_quoted_string_io 201304
90627f7eb2Smrg# define __cpp_lib_robust_nonmodifying_seq_ops 201304
91627f7eb2Smrg# ifdef _GLIBCXX_HAS_GTHREADS
92627f7eb2Smrg#  define __cpp_lib_shared_timed_mutex 201402
93627f7eb2Smrg# endif
94627f7eb2Smrg# define __cpp_lib_string_udls 201304
95627f7eb2Smrg# define __cpp_lib_transparent_operators 201510
96627f7eb2Smrg# define __cpp_lib_tuple_element_t 201402L
97627f7eb2Smrg# define __cpp_lib_tuples_by_type 201304
98*4c3eb207Smrg#endif
99627f7eb2Smrg
100627f7eb2Smrg#if __cplusplus >= 201703L
101627f7eb2Smrg// c++17
102627f7eb2Smrg#define __cpp_lib_addressof_constexpr 201603
103627f7eb2Smrg#define __cpp_lib_atomic_is_always_lock_free 201603
104627f7eb2Smrg#define __cpp_lib_bool_constant 201505
105627f7eb2Smrg#define __cpp_lib_byte 201603
106627f7eb2Smrg#ifdef _GLIBCXX_HAVE_BUILTIN_HAS_UNIQ_OBJ_REP
107627f7eb2Smrg# define __cpp_lib_has_unique_object_representations 201606
108627f7eb2Smrg#endif
109627f7eb2Smrg#ifdef _GLIBCXX_HAVE_BUILTIN_IS_AGGREGATE
110627f7eb2Smrg# define __cpp_lib_is_aggregate 201703
111627f7eb2Smrg#endif
112627f7eb2Smrg#define __cpp_lib_is_invocable 201703
113627f7eb2Smrg#define __cpp_lib_is_swappable 201603
114627f7eb2Smrg#ifdef _GLIBCXX_HAVE_BUILTIN_LAUNDER
115627f7eb2Smrg# define __cpp_lib_launder 201606
116627f7eb2Smrg#endif
117627f7eb2Smrg#define __cpp_lib_logical_traits 201510
118*4c3eb207Smrg#define __cpp_lib_type_trait_variable_templates 201510L
119*4c3eb207Smrg#define __cpp_lib_uncaught_exceptions 201411L
120*4c3eb207Smrg#define __cpp_lib_void_t 201411
121*4c3eb207Smrg
122*4c3eb207Smrg#if _GLIBCXX_HOSTED
123*4c3eb207Smrg#define __cpp_lib_any 201606L
124*4c3eb207Smrg#define __cpp_lib_apply 201603
125*4c3eb207Smrg#if __cplusplus == 201703L // N.B. updated value in C++20
126*4c3eb207Smrg# define __cpp_lib_array_constexpr 201803L
127*4c3eb207Smrg#endif
128*4c3eb207Smrg#define __cpp_lib_as_const 201510
129*4c3eb207Smrg#define __cpp_lib_boyer_moore_searcher 201603
130*4c3eb207Smrg#define __cpp_lib_chrono 201611
131*4c3eb207Smrg#define __cpp_lib_clamp 201603
132*4c3eb207Smrg#if __cplusplus == 201703L // N.B. updated value in C++20
133*4c3eb207Smrg# define __cpp_lib_constexpr_char_traits 201611L
134*4c3eb207Smrg# define __cpp_lib_constexpr_string 201611L
135*4c3eb207Smrg#endif
136*4c3eb207Smrg#define __cpp_lib_enable_shared_from_this 201603
137*4c3eb207Smrg#define __cpp_lib_execution 201902L // FIXME: should be 201603L
138*4c3eb207Smrg#define __cpp_lib_filesystem 201703
139*4c3eb207Smrg#define __cpp_lib_gcd 201606
140*4c3eb207Smrg#define __cpp_lib_gcd_lcm 201606
141*4c3eb207Smrg#define __cpp_lib_hypot 201603
142*4c3eb207Smrg#define __cpp_lib_invoke 201411L
143*4c3eb207Smrg#define __cpp_lib_lcm 201606
144627f7eb2Smrg#define __cpp_lib_make_from_tuple 201606
145627f7eb2Smrg#define __cpp_lib_map_try_emplace 201411
146627f7eb2Smrg#define __cpp_lib_math_special_functions 201603L
147627f7eb2Smrg#ifdef _GLIBCXX_HAS_GTHREADS
148627f7eb2Smrg# define __cpp_lib_memory_resource 201603
149627f7eb2Smrg#else
150627f7eb2Smrg# define __cpp_lib_memory_resource 1
151627f7eb2Smrg#endif
152627f7eb2Smrg#define __cpp_lib_node_extract 201606
153627f7eb2Smrg#define __cpp_lib_nonmember_container_access 201411
154627f7eb2Smrg#define __cpp_lib_not_fn 201603
155627f7eb2Smrg#define __cpp_lib_optional 201606L
156*4c3eb207Smrg#define __cpp_lib_parallel_algorithm 201603L
157627f7eb2Smrg#define __cpp_lib_raw_memory_algorithms 201606L
158627f7eb2Smrg#define __cpp_lib_sample 201603
159627f7eb2Smrg#ifdef _GLIBCXX_HAS_GTHREADS
160627f7eb2Smrg# define __cpp_lib_scoped_lock 201703
161627f7eb2Smrg# define __cpp_lib_shared_mutex 201505
162627f7eb2Smrg#endif
163627f7eb2Smrg#define __cpp_lib_shared_ptr_weak_type 201606
164*4c3eb207Smrg#define __cpp_lib_string_view 201803L
165*4c3eb207Smrg// #define __cpp_lib_to_chars 201611L
166627f7eb2Smrg#define __cpp_lib_unordered_map_try_emplace 201411
167627f7eb2Smrg#define __cpp_lib_variant 201606L
168*4c3eb207Smrg#endif
169627f7eb2Smrg
170627f7eb2Smrg#if __cplusplus > 201703L
171627f7eb2Smrg// c++2a
172*4c3eb207Smrg#define __cpp_lib_atomic_float 201711L
173*4c3eb207Smrg#define __cpp_lib_atomic_ref 201806L
174*4c3eb207Smrg#define __cpp_lib_atomic_value_initialization 201911L
175*4c3eb207Smrg#define __cpp_lib_bitops 201907L
176627f7eb2Smrg#define __cpp_lib_bounded_array_traits 201902L
177*4c3eb207Smrg// __cpp_lib_char8_t is defined in <bits/c++config.h>
178*4c3eb207Smrg#if __cpp_concepts >= 201907L
179*4c3eb207Smrg# define __cpp_lib_concepts 202002L
180*4c3eb207Smrg#endif
181627f7eb2Smrg#if __cpp_impl_destroying_delete
182627f7eb2Smrg# define __cpp_lib_destroying_delete 201806L
183627f7eb2Smrg#endif
184627f7eb2Smrg#define __cpp_lib_endian 201907L
185*4c3eb207Smrg#define __cpp_lib_int_pow2 202002L
186627f7eb2Smrg#ifdef _GLIBCXX_HAVE_BUILTIN_IS_CONSTANT_EVALUATED
187627f7eb2Smrg# define __cpp_lib_is_constant_evaluated 201811L
188627f7eb2Smrg#endif
189*4c3eb207Smrg#define __cpp_lib_is_nothrow_convertible 201806L
190*4c3eb207Smrg#define __cpp_lib_remove_cvref 201711L
191*4c3eb207Smrg#if __cpp_impl_three_way_comparison >= 201907L && __cpp_lib_concepts
192*4c3eb207Smrg# define __cpp_lib_three_way_comparison 201907L
193*4c3eb207Smrg#endif
194*4c3eb207Smrg#define __cpp_lib_type_identity 201806L
195*4c3eb207Smrg#define __cpp_lib_unwrap_ref 201811L
196*4c3eb207Smrg
197*4c3eb207Smrg#if _GLIBCXX_HOSTED
198*4c3eb207Smrg#define __cpp_lib_array_constexpr 201811L
199*4c3eb207Smrg#define __cpp_lib_assume_aligned 201811L
200*4c3eb207Smrg#define __cpp_lib_bind_front 201907L
201*4c3eb207Smrg// FIXME: #define __cpp_lib_execution 201902L
202*4c3eb207Smrg#define __cpp_lib_integer_comparison_functions 202002L
203*4c3eb207Smrg#define __cpp_lib_constexpr_algorithms 201806L
204*4c3eb207Smrg#ifdef __cpp_lib_is_constant_evaluated
205*4c3eb207Smrg# define __cpp_lib_constexpr_char_traits 201811L
206*4c3eb207Smrg#endif
207*4c3eb207Smrg#define __cpp_lib_constexpr_complex 201711L
208*4c3eb207Smrg#define __cpp_lib_constexpr_dynamic_alloc 201907L
209*4c3eb207Smrg#define __cpp_lib_constexpr_functional 201907L
210*4c3eb207Smrg#define __cpp_lib_constexpr_iterator 201811L
211*4c3eb207Smrg#define __cpp_lib_constexpr_memory 201811L
212*4c3eb207Smrg#define __cpp_lib_constexpr_numeric 201911L
213*4c3eb207Smrg#ifdef __cpp_lib_is_constant_evaluated
214*4c3eb207Smrg# define __cpp_lib_constexpr_string 201811L
215*4c3eb207Smrg#endif
216*4c3eb207Smrg#define __cpp_lib_constexpr_string_view 201811L
217*4c3eb207Smrg#define __cpp_lib_constexpr_tuple 201811L
218*4c3eb207Smrg#define __cpp_lib_constexpr_utility 201811L
219*4c3eb207Smrg#define __cpp_lib_erase_if 202002L
220*4c3eb207Smrg#define __cpp_lib_interpolate 201902L
221*4c3eb207Smrg#ifdef _GLIBCXX_HAS_GTHREADS
222*4c3eb207Smrg# define __cpp_lib_jthread 201911L
223*4c3eb207Smrg#endif
224627f7eb2Smrg#define __cpp_lib_list_remove_return_type 201806L
225*4c3eb207Smrg#define __cpp_lib_math_constants 201907L
226*4c3eb207Smrg#define __cpp_lib_polymorphic_allocator 201902L
227*4c3eb207Smrg#if __cpp_lib_concepts
228*4c3eb207Smrg# define __cpp_lib_ranges 201911L
229*4c3eb207Smrg#endif
230*4c3eb207Smrg#define __cpp_lib_shift 201806L
231*4c3eb207Smrg#if __cpp_lib_concepts
232*4c3eb207Smrg# define __cpp_lib_span 202002L
233*4c3eb207Smrg#endif
234*4c3eb207Smrg#define __cpp_lib_ssize 201902L
235*4c3eb207Smrg#define __cpp_lib_starts_ends_with 201711L
236*4c3eb207Smrg#define __cpp_lib_to_address 201711L
237*4c3eb207Smrg#define __cpp_lib_to_array 201907L
238*4c3eb207Smrg#endif
239627f7eb2Smrg#endif // C++2a
240627f7eb2Smrg#endif // C++17
241627f7eb2Smrg#endif // C++14
242627f7eb2Smrg#endif // C++11
243627f7eb2Smrg
244627f7eb2Smrg#endif // _GLIBCXX_VERSION_INCLUDED
245