Table of Contents
This status table is based on the table of contents of ISO/IEC 14882:2003.
This section describes the C++ support in mainline GCC, not in any particular release.
Table 1.1. C++ 1998/2003 Implementation Status
Section | Description | Status | Comments |
---|---|---|---|
18 | Language support | ||
18.1 | Types | Y | |
18.2 | Implementation properties | Y | |
18.2.1 | Numeric Limits | ||
18.2.1.1 | Class template numeric_limits | Y | |
18.2.1.2 | numeric_limits members | Y | |
18.2.1.3 | float_round_style | Y | |
18.2.1.4 | float_denorm_style | Y | |
18.2.1.5 | numeric_limits specializations | Y | |
18.2.2 | C Library | Y | |
18.3 | Start and termination | Y | |
18.4 | Dynamic memory management | Y | |
18.5 | Type identification | ||
18.5.1 | Class type_info | Y | |
18.5.2 | Class bad_cast | Y | |
18.5.3 | Class bad_typeid | Y | |
18.6 | Exception handling | ||
18.6.1 | Class exception | Y | |
18.6.2 | Violation exception-specifications | Y | |
18.6.3 | Abnormal termination | Y | |
18.6.4 | uncaught_exception | Y | |
18.7 | Other runtime support | Y | |
19 | Diagnostics | ||
19.1 | Exception classes | Y | |
19.2 | Assertions | Y | |
19.3 | Error numbers | Y | |
20 | General utilities | ||
20.1 | Requirements | Y | |
20.2 | Utility components | ||
20.2.1 | Operators | Y | |
20.2.2 | pair | Y | |
20.3 | Function objects | ||
20.3.1 | Base | Y | |
20.3.2 | Arithmetic operation | Y | |
20.3.3 | Comparisons | Y | |
20.3.4 | Logical operations | Y | |
20.3.5 | Negators | Y | |
20.3.6 | Binders | Y | |
20.3.7 | Adaptors for pointers to functions | Y | |
20.3.8 | Adaptors for pointers to members | Y | |
20.4 | Memory | ||
20.4.1 | The default allocator | Y | |
20.4.2 | Raw storage iterator | Y | |
20.4.3 | Temporary buffers | Y | |
20.4.4 | Specialized algorithms | Y | |
20.4.4.1 | uninitialized_copy | Y | |
20.4.4.2 | uninitialized_fill | Y | |
20.4.4.3 | uninitialized_fill_n | Y | |
20.4.5 | Class template auto_ptr | Y | |
20.4.6 | C library | Y | |
21 | Strings | ||
21.1 | Character traits | ||
21.1.1 | Character traits requirements | Y | |
21.1.2 | traits typedef | Y | |
21.1.3 | char_traits specializations | ||
21.1.3.1 | struct char_traits<char> | Y | |
21.1.3.2 | struct char_traits<wchar_t> | Y | |
21.2 | String classes | Y | |
21.3 | Class template basic_string | Y | |
21.4 | Null-terminated sequence utilities | Y | C library dependency |
22 | Localization | ||
22.1 | Locales | ||
22.1.1 | Class locale | Y | |
22.1.2 | locale globals | Y | |
22.1.3 | Convenience interfaces | ||
22.1.3.1 | Character classification | Y | |
22.1.3.2 | Character conversions | Y | |
22.2 | Standard locale categories | ||
22.2.1 | ctype | Y | |
22.2.2 | Numeric | ||
22.2.2.1 | num_get | Y | |
22.2.2.2 | num_put | Y | |
22.2.3 | num_punct | Y | |
22.2.4 | collate | Y | |
22.2.5 | Time | ||
22.2.5.1 | time_get | Y | |
22.2.5.2 | time_get_byname | Y | |
22.2.5.3 | time_put | Y | |
22.2.5.3 | time_put_byname | Y | |
22.2.6 | Monetary | ||
22.2.6.1 | money_get | Y | |
22.2.6.2 | money_put | Y | |
22.2.6.3 | money_punct | Y | |
22.2.6.4 | money_punct_byname | Y | |
22.2.7 | messages | Y | |
22.2.8 | Program-defined facets | Y | |
22.3 | C Library Locales | Y | |
23 | Containers | ||
23.1 | Container requirements | Y | |
23.2 | Sequence containers | ||
23.2.1 | Class template deque | Y | |
23.2.2 | Class template list | Y | |
23.2.3 | Adaptors | ||
23.2.3.1 | Class template queue | Y | |
23.2.3.2 | Class template priority_queue | Y | |
23.2.3.3 | Class template stack | Y | |
23.2.4 | Class template vector | Y | |
23.2.5 | Class vector<bool> | Y | |
23.3 | Associative containers | ||
23.3.1 | Class template map | Y | |
23.3.2 | Class template multimap | Y | |
23.3.3 | Class template set | Y | |
23.3.4 | Class template multiset | Y | |
24 | Iterators | ||
24.1 | Requirements | Y | |
24.2 | Header <iterator> synopsis | Y | |
24.3 | Iterator primitives | Y | |
24.4 | Predefined iterators and Iterator adaptors | ||
24.4.1 | Reverse iterators | Y | |
24.4.2 | Insert iterators | Y | |
24.5 | Stream iterators | ||
24.5.1 | Class template istream_iterator | Y | |
24.5.2 | Class template ostream_iterator | Y | |
24.5.3 | Class template istreambuf_iterator | Y | |
24.5.4 | Class template ostreambuf_iterator | Y | |
25 | Algorithms | ||
25.1 | Non-modifying sequence operations | Y | |
25.2 | Mutating sequence operations | Y | |
25.3 | Sorting and related operations | Y | |
25.4 | C library algorithms | Y | |
26 | Numerics | ||
26.1 | Numeric type requirements | Y | |
26.2 | Complex numbers | Y | |
26.3 | Numeric arrays | ||
26.3.1 | Header <valarray> synopsis | Y | |
26.3.2 | Class template valarray | Y | |
26.3.3 | valarray non-member operations | Y | |
26.3.4 | Class slice | Y | |
26.3.5 | Class template slice_array | Y | |
26.3.6 | Class gslice | Y | |
26.3.7 | Class template gslice_array | Y | |
26.3.8 | Class template mask_array | Y | |
26.3.9 | Class template indirect_array | Y | |
26.4 | Generalized numeric operations | ||
26.4.1 | accumulate | Y | |
26.4.2 | inner_product | Y | |
26.4.3 | partial_sum | Y | |
26.4.4 | adjacent_difference | Y | |
26.4.5 | iota | Y | |
26.5 | C Library | Y | |
27 | Input/output | ||
27.1 | Requirements | Y | |
27.2 | Forward declarations | Y | |
27.3 | Standard iostream objects | Y | |
27.3.1 | Narrow stream objects | Y | |
27.3.2 | Wide stream objects | Y | |
27.4 | Iostreams base classes | Y | |
27.5 | Stream buffers | Y | |
27.6 | Formatting and manipulators | Y | |
27.7 | String-based streams | Y | |
27.8 | File-based streams | Y | |
Appendix D | Compatibility features | ||
D.1 | Increment operator with bool operand | ||
D.2 | static keyword | ||
D.3 | Access declarations | ||
D.4 | Implicit conversion from const strings | ||
D.5 | C standard library headers | ||
D.6 | Old iostreams members | ||
D.7 | char* streams |
The ISO standard defines the following phrase:
[1.3.5] implementation-defined behavior
Behavior, for a well-formed program construct and correct data, that depends on the implementation and that each implementation shall document.
We do so here, for the C++ library only. Behavior of the compiler, linker, runtime loader, and other elements of "the implementation" are documented elsewhere. Everything listed in Annex B, Implementation Qualities, are also part of the compiler, not the library.
For each entry, we give the section number of the standard, when applicable. This list is probably incomplet and inkorrekt.
[1.9]/11 #3 If isatty(3)
is true, then
interactive stream support is implied.
[17.4.4.5] Non-reentrant functions are probably best discussed in the various sections on multithreading (see above).
[18.1]/4 The type of NULL
is described
under Support.
[18.3]/8 Even though it's listed in the library sections, libstdc++ has zero control over what the cleanup code hands back to the runtime loader. Talk to the compiler people. :-)
[18.4.2.1]/5 (bad_alloc),
[18.5.2]/5 (bad_cast),
[18.5.3]/5 (bad_typeid),
[18.6.1]/8 (exception),
[18.6.2.1]/5 (bad_exception): The what()
member function of class std::exception
, and these other
classes publicly derived from it, returns the name of the
class, e.g. "std::bad_alloc"
.
[18.5.1]/7 The return value of
std::type_info::name()
is the mangled type name.
You will need to call c++filt
and pass the names as
command-line parameters to demangle them, or call a
runtime demangler function.
[20.1.5]/5 "Implementors are encouraged to supply libraries that can accept allocators that encapsulate more general memory models and that support non-equal instances. In such implementations, any requirements imposed on allocators by containers beyond those requirements that appear in Table 32, and the semantics of containers and algorithms when allocator instances compare non-equal, are implementation-defined." There is experimental support for non-equal allocators in the standard containers in C++98 mode. There are no additional requirements on allocators. It is undefined behaviour to swap two containers if their allocators are not equal.
[21.1.3.1]/3,4, [21.1.3.2]/2, [21.3]/6 basic_string::iterator, basic_string::const_iterator, [23.*]'s foo::iterator, [27.*]'s foo::*_type, others... Nope, these types are called implementation-defined because you shouldn't be taking advantage of their underlying types. Listing them here would defeat the purpose. :-)
[21.1.3.1]/5 I don't really know about
the mbstate_t stuff... see
the codecvt
notes for what does exist.
[22.*] Anything and everything we have on locale implementation will be described under Localization.
[23.*] All of the containers in this clause define size_type as std::size_t and difference_type as std::ptrdiff_t.
[26.2.8]/9 I have no idea what
complex<T>
's pow(0,0)
returns.
[27.4.2.4]/2 Calling
std::ios_base::sync_with_stdio
after I/O has already been
performed on the standard stream objects will
flush the buffers, and
destroy and recreate the underlying buffer instances. Whether or not
the previously-written I/O is destroyed in this process depends mostly
on the --enable-libio
choice: for stdio, if the written
data is already in the stdio buffer, the data may be completely safe!
[27.6.1.1.2], [27.6.2.3] The I/O sentry ctor and dtor can perform additional work than the minimum required. We are not currently taking advantage of this yet.
[27.7.1.3]/16,
[27.8.1.4]/10
The effects of pubsetbuf/setbuf
are described in the
Input and Output chapter.
[27.8.1.4]/16 Calling fstream::sync
when
a get area exists will... whatever fflush()
does, I think.
This table is based on the table of contents of ISO/IEC JTC1 SC22 WG21 Doc No: N3290 Date: 2011-04-11 Final Draft International Standard, Standard for Programming Language C++
In this implementation the -std=gnu++11
or
-std=c++11
flag must be used to enable language
and library
features. See dialect
options. The pre-defined symbol
__cplusplus
is used to check for the
presence of the required flag.
This status table is based on the table of contents of ISO/IEC 14882:2011.
This section describes the C++11 support in mainline GCC, not in any particular release.
Table 1.2. C++ 2011 Implementation Status
Section | Description | Status | Comments | |
---|---|---|---|---|
18 | Language support | |||
18.1 | General | |||
18.2 | Types | Y | ||
18.3 | Implementation properties | |||
18.3.2 | Numeric Limits | |||
18.3.2.3 | Class template numeric_limits | Y | ||
18.3.2.4 | numeric_limits members | Y | ||
18.3.2.5 | float_round_style | N | ||
18.3.2.6 | float_denorm_style | N | ||
18.3.2.7 | numeric_limits specializations | Y | ||
18.3.3 | C Library | Y | ||
18.4 | Integer types | |||
18.4.1 | Header <cstdint> synopsis | Y | ||
18.5 | Start and termination | Partial | C library dependency for quick_exit, at_quick_exit | |
18.6 | Dynamic memory management | Y | ||
18.7 | Type identification | |||
18.7.1 | Class type_info | Y | ||
18.7.2 | Class bad_cast | Y | ||
18.7.3 | Class bad_typeid | Y | ||
18.8 | Exception handling | |||
18.8.1 | Class exception | Y | ||
18.8.2 | Class bad_exception | Y | ||
18.8.3 | Abnormal termination | Y | ||
18.8.4 | uncaught_exception | Y | ||
18.8.5 | Exception Propagation | Y | ||
18.8.6 | nested_exception | Y | ||
18.9 | Initializer lists | |||
18.9.1 | Initializer list constructors | Y | ||
18.9.2 | Initializer list access | Y | ||
18.9.3 | Initializer list range access | Y | ||
18.10 | Other runtime support | Y | ||
19 | Diagnostics | |||
19.1 | General | |||
19.2 | Exception classes | Y | ||
19.3 | Assertions | Y | ||
19.4 | Error numbers | Y | ||
19.5 | System error support | |||
19.5.1 | Class error_category | Y | ||
19.5.2 | Class error_code | Y | ||
19.5.3 | Class error_condition | Y | ||
19.5.4 | Comparison operators | Y | ||
19.5.5 | Class system_error | Y | ||
20 | General utilities | |||
20.1 | General | |||
20.2 | Utility components | |||
20.2.1 | Operators | Y | ||
20.2.2 | swap | Y | ||
20.2.3 | forward/move helpers | Y | ||
20.2.4 | Function template declval | Y | ||
20.3 | Pairs | |||
20.3.1 | In general | |||
20.3.2 | Class template pair | Y | ||
20.3.3 | Specialized algorithms | Y | ||
20.3.4 | Tuple-like access to pair | Y | ||
20.3.5 | Piecewise construction | Y | ||
20.4 | Tuples | |||
20.4.1 | In general | |||
20.4.2 | Class template tuple | |||
20.4.2.1 | Construction | Y | ||
20.4.2.2 | Assignment | Y | ||
20.4.2.3 | Swap | Y | ||
20.4.2.4 | Tuple creation functions | Y | ||
20.4.2.5 | Tuple helper classes | Y | ||
20.4.2.6 | Element access | Y | ||
20.4.2.7 | Relational operators | Y | ||
20.4.2.8 | Tuple traits | Y | ||
20.4.2.9 | Tuple specialized algorithms | Y | ||
20.5 | Class template bitset | Y | ||
20.5.1 | bitset constructors | Y | ||
20.5.2 | bitset members | Y | ||
20.5.3 | bitset hash support | Y | ||
20.5.4 | bitset operators | Y | ||
20.6 | Memory | |||
20.6.1 | In general | |||
20.6.2 | Header <memory> synopsis | |||
20.6.3 | Pointer traits | Y | ||
20.6.4 | Pointer safety | Y | ||
20.6.5 | Align | Y | ||
20.6.6 | Allocator argument tag | Y | ||
20.6.7 | uses_allocator | Y | ||
20.6.8 | Allocator traits | Y | ||
20.6.9 | The default allocator | Y | ||
20.6.10 | Raw storage iterator | Y | ||
20.6.11 | Temporary buffers | Y | ||
20.6.12 | Specialized algorithms | |||
20.6.12.1 | addressof | Y | ||
20.6.12.2 | uninitialized_copy | Y | ||
20.6.12.3 | uninitialized_fill | Y | ||
20.6.12.4 | uninitialized_fill_n | Y | ||
20.6.13 | C library | Y | ||
20.7 | Smart pointers | |||
20.7.1 | Class template unique_ptr | Y | ||
20.7.2 | Shared-ownership pointers | |||
20.7.2.1 | Class bad_weak_ptr | Y | ||
20.7.2.2 | Class template shared_ptr | Y | Uses code from boost::shared_ptr. | |
20.7.2.3 | Class template weak_ptr | Y | ||
20.7.2.4 | Class template enable_shared_from_this | Y | ||
20.7.2.5 | shared_ptr atomic access | Y | ||
20.7.2.6 | Smart pointer hash support | Y | ||
20.8 | Function objects | |||
20.8.1 | Definitions | |||
20.8.2 | Requirements | |||
20.8.3 | Class template reference_wrapper | Y | ||
20.8.4 | Arithmetic operation | Y | ||
20.8.5 | Comparisons | Y | ||
20.8.6 | Logical operations | Y | ||
20.8.7 | Bitwise operations | Y | ||
20.8.8 | Negators | Y | ||
20.8.9 | Function template bind | Y | ||
20.8.10 | Function template mem_fn | Y | ||
20.8.11 | Polymorphic function wrappers | |||
20.8.11.1 | Class bad_function_call | Y | ||
20.8.11.2 | Class template function | Partial | Missing allocator support | |
20.8.12 | Class template hash | Y | ||
20.9 | Metaprogramming and type traits | |||
20.9.1 | Requirements | Y | ||
20.9.2 | Header <type_traits> synopsis | |||
20.9.3 | Helper classes | Y | ||
20.9.4 | Unary Type Traits | Y | ||
20.9.4.1 | Primary type categories | Y | ||
20.9.4.2 | Composite type traits | Y | ||
20.9.4.3 | Type properties | Y | ||
20.9.5 | Type property queries | Y | ||
20.9.6 | Relationships between types | Y | ||
20.9.7 | Transformations between types | |||
20.9.7.1 | Const-volatile modifications | Y | ||
20.9.7.2 | Reference modifications | Y | ||
20.9.7.3 | Sign modifications | Y | ||
20.9.7.4 | Array modifications | Y | ||
20.9.7.5 | Pointer modifications | Y | ||
20.9.7.6 | Other transformations | Y | ||
20.10 | Compile-time rational arithmetic | |||
20.10.1 | In general | |||
20.10.2 | Header <ratio> synopsis | |||
20.10.3 | Class template ratio | Y | ||
20.10.4 | Arithmetic on ratio s | Y | ||
20.10.5 | Comparison of ratio s | Y | ||
20.10.6 | SI types for ratio | Y | ||
20.11 | Time utilities | |||
20.11.3 | Clock requirements | Y | ||
20.11.4 | Time-related traits | |||
20.11.4.1 | treat_as_floating_point | Y | ||
20.11.4.2 | duration_values | Y | ||
20.11.4.3 | Specializations of common_type | Y | ||
20.11.5 | Class template duration | Y | ||
20.11.6 | Class template time_point | Y | ||
20.11.7 | Clocks | |||
20.11.7.1 | Class system_clock | Y | ||
20.11.7.2 | Class steady_clock | Y | ||
20.11.7.3 | Class high_resolution_clock | Y | ||
20.11.8 | Date and time functions | Y | ||
20.12 | Scoped allocator adaptor | Y | ||
20.12.1 | Header <scoped_allocator> synopsis | |||
20.12.2 | Scoped allocator adaptor member types | Y | ||
20.12.3 | Scoped allocator adaptor constructors | Y | ||
20.12.4 | Scoped allocator adaptor members | Y | ||
20.12.5 | Scoped allocator operators | Y | ||
20.13 | Class type_index | Y | ||
21 | Strings | |||
21.1 | General | Y | ||
21.2 | Character traits | |||
21.2.1 | Character traits requirements | Y | ||
21.2.2 | traits typedefs | Y | ||
21.2.3 | char_traits specializations | |||
21.2.3.1 | struct char_traits<char> | Y | ||
21.2.3.2 | struct char_traits<char16_t> | Y | ||
21.2.3.3 | struct char_traits<char32_t> | Y | ||
21.2.3.4 | struct char_traits<wchar_t> | Y | ||
21.3 | String classes | Y | ||
21.4 | Class template basic_string | Y | ||
21.5 | Numeric Conversions | Y | ||
21.6 | Hash support | Y | ||
21.7 | Null-terminated sequence utilities | Partial | C library dependency. | |
22 | Localization | |||
22.1 | General | Y | ||
22.2 | Header <locale> synopsis | Y | ||
22.3 | Locales | |||
22.3.1 | Class locale | Y | ||
22.3.2 | locale globals | Y | ||
22.3.3 | Convenience interfaces | |||
22.3.3.1 | Character classification | Y | ||
22.3.3.2 | Conversions | |||
22.3.3.2.1 | Character conversions | Y | ||
22.3.3.2.2 | string conversions | Y | ||
22.3.3.2.3 | Buffer conversions | Y | ||
22.4 | Standard locale categories | |||
22.4.1 | The ctype category | Y | ||
22.4.2 | The numeric category | |||
22.4.2.1 | num_get | Y | ||
22.4.2.2 | num_put | Y | ||
22.4.3 | The numeric punctuation facet | Y | ||
22.4.4 | The collate category | Y | ||
22.4.5 | The time category | |||
22.4.5.1 | Class template time_get | Y | ||
22.4.5.2 | Class template time_get_byname | Y | ||
22.4.5.3 | Class template time_put | Y | ||
22.4.5.3 | Class template time_put_byname | Y | ||
22.4.6 | The monetary category | |||
22.4.6.1 | Class template money_get | Y | ||
22.4.6.2 | Class template money_put | Y | ||
22.4.6.3 | Class template money_punct | Y | ||
22.4.6.4 | Class template money_punct_byname | Y | ||
22.4.7 | The message retrieval category | Y | ||
22.4.8 | Program-defined facets | Y | ||
22.5 | Standard code conversion facets | Y | ||
22.6 | C Library Locales | Y | ||
23 | Containers | |||
23.1 | General | |||
23.2 | Container requirements | |||
23.2.1 | General container requirements | Y | ||
23.2.2 | Container data races | Y | ||
23.2.3 | Sequence containers | Y | ||
23.2.4 | Associative containers | Y | ||
23.2.5 | Unordered associative containers | Y | ||
23.3 | Sequence containers | |||
23.3.2 | Class template array | Y | ||
23.3.3 | Class template deque | Y | ||
23.3.4 | Class template forward_list | Y | ||
23.3.5 | Class template list | Y | ||
23.3.6 | Class template vector | Y | ||
23.3.7 | Class vector<bool> | Y | ||
23.4 | Associative containers | |||
23.4.4 | Class template map | Y | ||
23.4.5 | Class template multimap | Y | ||
23.4.6 | Class template set | Y | ||
23.4.7 | Class template multiset | Y | ||
23.5 | Unordered associative containers | |||
23.5.4 | Class template unordered_map | Y | ||
23.5.5 | Class template unordered_multimap | Y | ||
23.5.6 | Class template unordered_set | Y | ||
23.5.7 | Class template unordered_multiset | Y | ||
23.6 | Container adaptors | |||
23.6.1 | Class template queue | Y | ||
23.6.2 | Class template priority_queue | Y | ||
23.6.3 | Class template stack | Y | ||
24 | Iterators | |||
24.1 | General | Y | ||
24.2 | Iterator requirements | Y | ||
24.3 | Header <iterator> synopsis | Y | ||
24.4 | Iterator primitives | Y | ||
24.5 | Iterator adaptors | |||
24.5.1 | Reverse iterators | Y | ||
24.5.2 | Insert iterators | Y | ||
24.5.3 | Move iterators | Y | ||
24.6 | Stream iterators | |||
24.6.1 | Class template istream_iterator | Y | ||
24.6.2 | Class template ostream_iterator | Y | ||
24.6.3 | Class template istreambuf_iterator | Y | ||
24.6.4 | Class template ostreambuf_iterator | Y | ||
24.6.5 | range access | Y | ||
25 | Algorithms | |||
25.1 | General | |||
25.2 | Non-modifying sequence operations | Y | ||
25.3 | Mutating sequence operations | Y | ||
25.4 | Sorting and related operations | Y | ||
25.5 | C library algorithms | Y | ||
26 | Numerics | |||
26.1 | General | |||
26.2 | Numeric type requirements | Y | ||
26.3 | The floating-point environment | Y | ||
26.4 | Complex numbers | Y | ||
26.5 | Random number generation | |||
26.5.1 | Requirements | |||
26.5.2 | Header <random> synopsis | |||
26.5.3 | Random number engine class templates | |||
26.5.3.1 | Class template linear_congruential_engine | Y | ||
26.5.3.2 | Class template mersenne_twister_engine | Y | ||
26.5.3.3 | Class template subtract_with_carry_engine | Y | ||
26.5.4 | Random number engine adaptor class templates | |||
26.5.4.2 | Class template discard_block_engine | Y | ||
26.5.4.3 | Class template independent_bits_engine | Y | ||
26.5.4.4 | Class template shuffle_order_engine | Y | ||
26.5.5 | Engines and engine adaptors with predefined parameters | Y | ||
26.5.6 | Class random_device | Y | ||
26.5.7 | Utilities | |||
26.5.7.1 | Class seed_seq | Y | ||
26.5.7.2 | Function template generate_canonical | Y | ||
26.5.8 | Random number distribution class templates | |||
26.5.8.2 | Uniform distributions | |||
26.5.8.2.1 | Class template uniform_int_distribution | Y | ||
26.5.8.2.2 | Class template uniform_real_distribution | Y | ||
26.5.8.3 | Bernoulli distributions | |||
26.5.8.3.1 | Class bernoulli_distribution | Y | ||
26.5.8.3.2 | Class template binomial_distribution | Y | ||
26.5.8.3.3 | Class template geometric_distribution | Y | ||
26.5.8.3.4 | Class template negative_binomial_distribution | Y | ||
26.5.8.4 | Poisson distributions | |||
26.5.8.4.1 | Class template poisson_distribution | Y | ||
26.5.8.4.2 | Class template exponential_distribution | Y | ||
26.5.8.4.3 | Class template gamma_distribution | Y | ||
26.5.8.4.4 | Class template weibull_distribution | Y | ||
26.5.8.4.5 | Class template extreme_value_distribution | Y | ||
26.5.8.5 | Normal distributions | |||
26.5.8.5.1 | Class template normal_distribution | Y | ||
26.5.8.5.2 | Class template lognormal_distribution | Y | ||
26.5.8.5.3 | Class template chi_squared_distribution | Y | ||
26.5.8.5.4 | Class template cauchy_distribution | Y | ||
26.5.8.5.5 | Class template fisher_f_distribution | Y | ||
26.5.8.5.6 | Class template student_t_distribution | Y | ||
26.5.8.6 | Sampling distributions | |||
26.5.8.6.1 | Class template discrete_distribution | Y | ||
26.5.8.6.2 | Class template piecewise_constant_distribution | Y | ||
26.5.8.6.3 | Class template piecewise_linear_distribution | Y | ||
26.6 | Numeric arrays | |||
26.6.1 | Header <valarray> synopsis | Y | ||
26.6.2 | Class template valarray | Y | ||
26.6.3 | valarray non-member operations | Y | ||
26.6.4 | Class slice | Y | ||
26.6.5 | Class template slice_array | Y | ||
26.6.6 | The gslice class | Y | ||
26.6.7 | Class template gslice_array | Y | ||
26.6.8 | Class template mask_array | Y | ||
26.6.9 | Class template indirect_array | Y | ||
26.6.10 | valarray range access | Y | ||
26.7 | Generalized numeric operations | |||
26.7.1 | Header <numeric> synopsis | Y | ||
26.7.2 | Accumulate> | Y | ||
26.7.3 | Inner product | Y | ||
26.7.4 | Partial sum | Y | ||
26.7.5 | Adjacent difference | Y | ||
26.7.6 | Iota | Y | ||
26.8 | C Library | Y | ||
27 | Input/output library | |||
27.1 | General | Y | ||
27.2 | Iostreams requirements | Y | ||
27.2.1 | Imbue Limitations | Y | ||
27.2.2 | Positioning Type Limitations | Y | ||
27.2.3 | Thread safety | Partial | ||
27.3 | Forward declarations | Y | ||
27.4 | Standard iostream objects | Y | ||
27.4.1 | Overview | Y | ||
27.4.2 | Narrow stream objects | Y | ||
27.4.3 | Wide stream objects | Y | ||
27.5 | Iostreams base classes | Y | ||
27.6 | Stream buffers | Y | ||
27.7 | Formatting and manipulators | Y | ||
27.8 | String-based streams | Y | ||
27.9 | File-based streams | Y | ||
28 | Regular expressions | |||
28.1 | General | Y | ||
28.2 | Definitions | Y | ||
28.3 | Requirements | Y | ||
28.4 | Header <regex> synopsis | Y | ||
28.5 | Namespace std::regex_constants | Y | ||
28.6 | Class regex_error | Y | ||
28.7 | Class template regex_traits | Partial | transform_primary is not correctly implemented | |
28.8 | Class template basic_regex | Y | ||
28.9 | Class template sub_match | Y | ||
28.10 | Class template match_results | Y | ||
28.11 | Regular expression algorithms | Y | ||
28.12 | Regular expression Iterators | Y | ||
28.13 | Modified ECMAScript regular expression grammar | Y | ||
29 | Atomic operations | |||
29.1 | General | Y | ||
29.2 | Header <atomic> synopsis | Y | ||
29.3 | Order and consistency | Y | ||
29.4 | Lock-free property | Y | ||
29.5 | Atomic types | Y | ||
29.6 | Operations on atomic types | Y | ||
29.7 | Flag Type and operations | Y | ||
29.8 | Fences | Y | ||
30 | Thread support | |||
30.1 | General | Y | ||
30.2 | Requirements | Y | ||
30.3 | Threads | |||
30.3.1 | Class thread | Partial | thread::id comparisons not well-defined | |
30.3.2 | Namespace this_thread | Y | ||
30.4 | Mutual exclusion | |||
30.4.1 | Mutex requirements | |||
30.4.1.1 | In general | |||
30.4.1.2 | Mutex types | |||
30.4.1.2.1 | Class mutex | Y | ||
30.4.1.2.2 | Class recursive_mutex | Y | ||
30.4.1.3 | Timed mutex types | |||
30.4.1.3.1 | Class timed_mutex | Y | ||
30.4.1.3.2 | Class recursive_timed_mutex | Y | ||
30.4.2 | Locks | |||
30.4.2.1 | Class template lock_guard | Y | ||
30.4.2.2 | Class template unique_lock | Y | ||
30.4.3 | Generic locking algorithms | Y | ||
30.4.4 | Call once | |||
30.4.4.1 | Struct once_flag | Y | ||
30.4.4.2 | Function call_once | Broken | See PR 66146 | |
30.5 | Condition variables | Y | ||
30.5.1 | Class condition_variable | Y | ||
30.5.2 | Class condition_variable_any | Y | ||
30.6 | Futures | |||
30.6.1 | Overview | |||
30.6.2 | Error handling | Y | ||
30.6.3 | Class future_error | Y | ||
30.6.4 | Shared state | Y | ||
30.6.5 | Class template promise | Y | ||
30.6.6 | Class template future | Y | ||
30.6.7 | Class template shared_future | Y | ||
30.6.8 | Function template async | Y | ||
30.6.9 | Class template packaged_task | Y | ||
Appendix D | Compatibility features | |||
D.1 | Increment operator with bool operand | |||
D.2 | register keyword | |||
D.3 | Implicit declaration of copy functions | |||
D.4 | Dynamic exception specifications | |||
D.5 | C standard library headers | Y | ||
D.6 | Old iostreams members | Y | ||
D.7 | char* streams | Y | ||
D.8 | Function objects | Y | ||
D.9 | Binders | Y | ||
D.10 | auto_ptr | Y | ||
D.11 | Violating exception-specifications | Y |
For behaviour which is also specified by the 1998 and 2003 standards, see C++ 1998/2003 Implementation Specific Behavior. This section only documents behaviour which is new in the 2011 standard.
17.6.5.12 [res.on.exception.handling] There are no implementation-defined exception classes, only standard exception classes (or classes derived from them) will be thrown.
17.6.5.14 [value.error.codes]
The error_category
for errors originating outside
the OS, and the possible error code values for each error category,
should be documented here.
18.6.2.2 [new.badlength]
what()
returns
"std::bad_array_new_length"
.
20.6.9.1 [allocator.member]/5
Over-aligned types are not supported by
std::allocator
.
20.7.2.2.1 [util.smartptr.shared.const]
When a shared_ptr
constructor fails
bad_alloc
(or types derived from it) will
be thrown, or when an allocator is passed to the constructor then any
exceptions thrown by the allocator.
20.7.2.0 [util.smartptr.weakptr]
what()
returns "bad_weak_ptr"
.
20.8.9.1.3 [func.bind.place]/1 There are 29
placeholders defined and the placeholder types are
CopyAssignable
.
20.11.7.1 [time.clock.system]/3, /4
Time point values are truncated to time_t
values.
There is no loss of precision for conversions in the other direction.
20.15.7 [meta.trans]/2
aligned_storage
does not support extended
alignment.
21.2.3.2 [char.traits.specializations.char16_t],
21.2.3.3 [char.traits.specializations.char32_t]
The types u16streampos
and
u32streampos
are both synonyms for
fpos<mbstate_t>
.
The function eof
returns int_type(-1)
.
char_traits<char16_t>::to_int_type
will
transform the "noncharacter" U+FFFF to U+FFFD (REPLACEMENT CHARACTER).
This is done to ensure that to_int_type
never
returns the same value as eof
, which is U+FFFF.
22.3.1 [locale] There is one global locale for the whole program, not per-thread.
22.4.5.1.2 [locale.time.get.virtuals], 22.4.5.3.2 [locale.time.put.virtuals] Additional supported formats should be documented here.
22.4.7.1.2 [locale.messages.virtuals] The mapping should be documented here.
23.3.2.1 [array.overview]
array<T, N>::iterator
is T*
and
array<T, N>::const_iterator
is
const T*
.
23.5.4.2 [unord.map.cnstr], 23.5.5.2 [unord.multimap.cnstr], 23.5.6.2 [unord.set.cnstr], 23.5.7.2 [unord.multiset.cnstr] The default minimal bucket count is 0 for the default constructors, range constructors and initializer-list constructors.
25.3.12 [alg.random.shuffle]
The two-argument overload of random_shuffle
uses rand
as the source of randomness.
26.5.5 [rand.predef]
The type default_random_engine
is a synonym for
minstd_rand0
.
26.5.6 [rand.device]
The token
parameter of the
random_device
constructor can be used to select
a specific source of random bytes. The valid token values are shown
in the list below.
The default constructor uses the token "default"
.
"default"
"rand_s"
rand_s
function.
This token is only valid for mingw-w64 targets.
"rdseed"
, "rdrand"
or "rdrnd"
RDSEED
or RDRAND
instruction to read from an on-chip hardware random number generator.
These tokens are only valid for x86 and x86_64 targets when both
the assembler and CPU support the corresponding instruction.
"/dev/urandom"
, "/dev/random"
"mt19937"
, seed valuemersenne_twister_engine
will be used.
An integer seed value can be used as the token and will be converted
to an unsigned long
using strtoul
.
These tokens are only valid when no other source of random bytes
is available.
An exception of type runtime_error
will be
thrown if a random_device
object is constructed
with an invalid token, or if it cannot open or read from the source
of random bytes.
26.5.8.1 [rand.dist.general] The algorithms used by the distributions should be documented here.
26.8 [c.math] Whether the
rand
function introduces data races depends on
the C library as the function is not provided by libstdc++.
27.8.2.1 [stringbuf.cons]
Whether the sequence pointers are copied by the
basic_stringbuf
move constructor should be
documented here.
27.9.1.2 [filebuf.cons]
Whether the sequence pointers are copied by the
basic_filebuf
move constructor should be
documented here.
28.5.1 [re.synopt],
28.5.2 [re.matchflag] ,
28.5.3 [re.err]
syntax_option_type
, match_flag_type
and error_type
are unscoped enumeration types.
28.7 [re.traits]
The blank
character class corresponds to the
ctype_base::blank
mask.
29.4 [atomics.lockfree]
The values of the ATOMIC_xxx_LOCK_FREE
macros depend on
the target and cannot be listed here.
30.2.3 [thread.req.native]/1
native_handle_type
and
native_handle
are provided. The handle types
are defined in terms of the Gthreads abstraction layer, although this
is subject to change at any time. Any use of
native_handle
is inherently non-portable and
not guaranteed to work between major releases of GCC.
thread
__gthread_t
i.e. pthread_t
when GCC is configured with the
posix
thread model.
The value of the native handle is undefined for a thread
which is not joinable.
mutex
, timed_mutex
__gthread_mutex_t*
i.e.
pthread_mutex_t*
for the posix
thread model.
recursive_mutex
, recursive_timed_mutex
__gthread_recursive_mutex_t*
i.e. pthread_mutex_t*
for the posix
thread model.
condition_variable
__gthread_cond_t*
i.e.
pthread_cond_t*
for the posix
thread model.
30.6.1 [futures.overview]/2
launch
is a scoped enumeration type with
overloaded operators to support bitmask operations. There are no
additional bitmask elements defined.
In this implementation the -std=gnu++14
or
-std=c++14
flag must be used to enable language
and library
features. See dialect
options. The pre-defined symbol
__cplusplus
is used to check for the
presence of the required flag.
This status table is based on the table of contents of ISO/IEC 14882:2014. Some subclauses are not shown in the table where the content is unchanged since C++11 and the implementation is complete.
This section describes the C++14 and library TS support in mainline GCC, not in any particular release.
Table 1.3. C++ 2014 Implementation Status
Section | Description | Status | Comments | |
---|---|---|---|---|
18 | Language support | |||
18.1 | General | |||
18.2 | Types | Y | ||
18.3 | Implementation properties | |||
18.3.2 | Numeric Limits | |||
18.3.2.3 | Class template numeric_limits | Y | ||
18.3.2.4 | numeric_limits members | Y | ||
18.3.2.5 | float_round_style | N | ||
18.3.2.6 | float_denorm_style | N | ||
18.3.2.7 | numeric_limits specializations | Y | ||
18.3.3 | C Library | Y | ||
18.4 | Integer types | |||
18.4.1 | Header <cstdint> synopsis | Y | ||
18.5 | Start and termination | Partial | C library dependency for quick_exit, at_quick_exit | |
18.6 | Dynamic memory management | Y | ||
18.7 | Type identification | |||
18.7.1 | Class type_info | Y | ||
18.7.2 | Class bad_cast | Y | ||
18.7.3 | Class bad_typeid | Y | ||
18.8 | Exception handling | |||
18.8.1 | Class exception | Y | ||
18.8.2 | Class bad_exception | Y | ||
18.8.3 | Abnormal termination | Y | ||
18.8.4 | uncaught_exception | Y | ||
18.8.5 | Exception Propagation | Y | ||
18.8.6 | nested_exception | Y | ||
18.9 | Initializer lists | |||
18.9.1 | Initializer list constructors | Y | ||
18.9.2 | Initializer list access | Y | ||
18.9.3 | Initializer list range access | Y | ||
18.10 | Other runtime support | Y | ||
19 | Diagnostics | |||
19.1 | General | |||
19.2 | Exception classes | Y | ||
19.3 | Assertions | Y | ||
19.4 | Error numbers | Y | ||
19.5 | System error support | |||
19.5.1 | Class error_category | Y | ||
19.5.2 | Class error_code | Y | ||
19.5.3 | Class error_condition | Y | ||
19.5.4 | Comparison operators | Y | ||
19.5.5 | Class system_error | Y | ||
20 | General utilities | |||
20.1 | General | |||
20.2 | Utility components | |||
20.2.1 | Operators | Y | ||
20.2.2 | swap | Y | ||
20.2.3 | exchange | Y | ||
20.2.4 | forward/move helpers | Y | ||
20.2.5 | Function template declval | Y | ||
20.3 | Pairs | Y | ||
20.4 | Tuples | Y | ||
20.5 | Compile-time integer sequences | |||
20.5.2 | Class template integer_sequence | Y | ||
20.5.3 | Alias template make_integer_sequence | Y | ||
20.6 | Class template bitset | Y | ||
20.7 | Memory | Y | ||
20.8 | Smart pointers | |||
20.8.1 | Class template unique_ptr | Y | ||
20.8.1.1 | Default deleters | Y | ||
20.8.1.2 | unique_ptr for single objects | Y | ||
20.8.1.3 | unique_ptr for array objects with a runtime length | Y | ||
20.8.1.4 | unique_ptr creation | Y | ||
20.8.1.5 | unique_ptr specialized algorithms | Y | ||
20.8.2 | Shared-ownership pointers | |||
20.8.2.1 | Class bad_weak_ptr | Y | ||
20.8.2.2 | Class template shared_ptr | Y | Uses code from boost::shared_ptr. | |
20.8.2.3 | Class template weak_ptr | Y | ||
20.8.2.4 | Class template owner_less | Y | ||
20.8.2.5 | Class template enable_shared_from_this | Y | ||
20.8.2.6 | shared_ptr atomic access | Y | ||
20.8.2.7 | Smart pointer hash support | Y | ||
20.9 | Function objects | |||
20.9.1 | Definitions | |||
20.9.2 | Requirements | |||
20.9.3 | Class template reference_wrapper | Y | ||
20.9.4 | Arithmetic operation | Y | ||
20.9.5 | Comparisons | Y | ||
20.8.6 | Logical operations | Y | ||
20.9.7 | Bitwise operations | Y | ||
20.9.8 | Negators | Y | ||
20.9.9 | Function object binders | Y | ||
20.9.10 | Function template mem_fn | Y | ||
20.9.11 | Polymorphic function wrappers | |||
20.9.11.1 | Class bad_function_call | Y | ||
20.9.11.2 | Class template function | Partial | Missing allocator support | |
20.9.12 | Class template hash | Y | ||
20.10 | Metaprogramming and type traits | |||
20.10.1 | Requirements | Y | ||
20.10.2 | Header <type_traits> synopsis | |||
20.10.3 | Helper classes | Y | ||
20.10.4 | Unary Type Traits | Y | ||
20.10.5 | Type property queries | Y | ||
20.10.6 | Relationships between types | Y | ||
20.10.7 | Transformations between types | Y | ||
20.11 | Compile-time rational arithmetic | Y | ||
20.12 | Time utilities | |||
20.12.3 | Clock requirements | Y | ||
20.12.4 | Time-related traits | Y | ||
20.12.5 | Class template duration | Y | ||
20.12.5.8 | Suffixes for duration literals | Y | ||
20.12.6 | Class template time_point | Y | ||
20.12.7 | Clocks | Y | ||
20.12.8 | Date and time functions | Y | ||
20.13 | Scoped allocator adaptor | Y | ||
20.14 | Class type_index | Y | ||
21 | Strings | |||
21.1 | General | Y | ||
21.2 | Character traits | Y | ||
21.3 | String classes | Y | ||
21.4 | Class template basic_string | Y | ||
21.5 | Numeric Conversions | Y | ||
21.6 | Hash support | Y | ||
21.7 | Suffixes for basic_string literals | Y | ||
21.7 | Null-terminated sequence utilities | Partial | C library dependency. | |
22 | Localization | |||
22.1 | General | Y | ||
22.2 | Header <locale> synopsis | Y | ||
22.3 | Locales | Y | ||
22.4 | Standard locale categories | Y | ||
22.5 | Standard code conversion facets | Y | ||
22.6 | C Library Locales | Y | ||
23 | Containers | |||
23.1 | General | |||
23.2 | Container requirements | Y | ||
23.3 | Sequence containers | Y | ||
23.4 | Associative containers | Y | ||
23.5 | Unordered associative containers | Y | ||
23.6 | Container adaptors | Y | ||
24 | Iterators | |||
24.1 | General | Y | ||
24.2 | Iterator requirements | Y | ||
24.3 | Header <iterator> synopsis | Y | ||
24.4 | Iterator primitives | Y | ||
24.5 | Iterator adaptors | Y | ||
24.6 | Stream iterators | Y | ||
24.7 | range access | Y | ||
25 | Algorithms | |||
25.1 | General | |||
25.2 | Non-modifying sequence operations | Y | ||
25.3 | Mutating sequence operations | Y | ||
25.4 | Sorting and related operations | Y | ||
25.5 | C library algorithms | Y | ||
26 | Numerics | |||
26.1 | General | |||
26.2 | Numeric type requirements | Y | ||
26.3 | The floating-point environment | Y | ||
26.4 | Complex numbers | Y | ||
26.4.10 | Suffixes for complex number literals | Y | ||
26.5 | Random number generation | Y | ||
26.6 | Numeric arrays | Y | ||
26.7 | Generalized numeric operations | Y | ||
26.8 | C Library | Y | ||
27 | Input/output library | |||
27.1 | General | Y | ||
27.2 | Iostreams requirements | Y | ||
27.2.1 | Imbue Limitations | Y | ||
27.2.2 | Positioning Type Limitations | Y | ||
27.2.3 | Thread safety | Partial | ||
27.3 | Forward declarations | Y | ||
27.4 | Standard iostream objects | Y | ||
27.5 | Iostreams base classes | Y | ||
27.6 | Stream buffers | Y | ||
27.7 | Formatting and manipulators | Y | ||
27.7.6 | Quoted manipulators | Y | ||
27.8 | String-based streams | Y | ||
27.9 | File-based streams | Y | ||
28 | Regular expressions | |||
28.1 | General | Y | ||
28.2 | Definitions | Y | ||
28.3 | Requirements | Y | ||
28.4 | Header <regex> synopsis | Y | ||
28.5 | Namespace std::regex_constants | Y | ||
28.6 | Class regex_error | Y | ||
28.7 | Class template regex_traits | Partial | transform_primary is not correctly implemented | |
28.8 | Class template basic_regex | Y | ||
28.9 | Class template sub_match | Y | ||
28.10 | Class template match_results | Y | ||
28.11 | Regular expression algorithms | Y | ||
28.12 | Regular expression Iterators | Y | ||
28.13 | Modified ECMAScript regular expression grammar | Y | ||
29 | Atomic operations | |||
29.1 | General | Y | ||
29.2 | Header <atomic> synopsis | Y | ||
29.3 | Order and consistency | Y | ||
29.4 | Lock-free property | Y | ||
29.5 | Atomic types | Y | ||
29.6 | Operations on atomic types | Y | ||
29.7 | Flag Type and operations | Y | ||
29.8 | Fences | Y | ||
30 | Thread support | |||
30.1 | General | Y | ||
30.2 | Requirements | Y | ||
30.3 | Threads | |||
30.3.1 | Class thread | Partial | thread::id comparisons not well-defined | |
30.3.2 | Namespace this_thread | Y | ||
30.4 | Mutual exclusion | |||
30.4.1 | Mutex requirements | |||
30.4.1.1 | In general | |||
30.4.1.2 | Mutex types | |||
30.4.1.2.1 | Class mutex | Y | ||
30.4.1.2.2 | Class recursive_mutex | Y | ||
30.4.1.3 | Timed mutex types | |||
30.4.1.3.1 | Class timed_mutex | Y | ||
30.4.1.3.2 | Class recursive_timed_mutex | Y | ||
30.4.1.4 | Shared timed mutex types | |||
30.4.1.4.1 | Class shared_timed_mutex | Y | ||
30.4.2 | Locks | |||
30.4.2.1 | Class template lock_guard | Y | ||
30.4.2.2 | Class template unique_lock | Y | ||
30.4.2.3 | Class template shared_lock | Y | ||
30.4.3 | Generic locking algorithms | Y | ||
30.4.4 | Call once | |||
30.4.4.1 | Struct once_flag | Y | ||
30.4.4.2 | Function call_once | Broken | See PR 66146 | |
30.5 | Condition variables | Y | ||
30.5.1 | Class condition_variable | Y | ||
30.5.2 | Class condition_variable_any | Y | ||
30.6 | Futures | |||
30.6.1 | Overview | |||
30.6.2 | Error handling | Y | ||
30.6.3 | Class future_error | Y | ||
30.6.4 | Shared state | Y | ||
30.6.5 | Class template promise | Y | ||
30.6.6 | Class template future | Y | ||
30.6.7 | Class template shared_future | Y | ||
30.6.8 | Function template async | Y | ||
30.6.9 | Class template packaged_task | Y | ||
Appendix D | Compatibility features | |||
D.1 | Increment operator with bool operand | |||
D.2 | register keyword | |||
D.3 | Implicit declaration of copy functions | |||
D.4 | Dynamic exception specifications | |||
D.5 | C standard library headers | Y | ||
D.6 | Old iostreams members | Y | ||
D.7 | char* streams | Y | ||
D.8 | Function objects | Y | ||
D.9 | Binders | Y | ||
D.10 | auto_ptr | Y | ||
D.11 | Violating exception-specifications | Y | ||
D.12 | Random shuffle | Y |
Table 1.4. C++ Technical Specifications Implementation Status
Paper | Title | Status | Comments |
---|---|---|---|
N3662 | C++ Dynamic Arrays | N | Array Extensions TS |
N3793 | A proposal to add a utility class to represent optional objects | Y | Library Fundamentals TS |
N3804 | Any library proposal | Y | Library Fundamentals TS |
N3866 | Invocation type traits, but dropping function_call_operator. | N | Library Fundamentals TS |
N3905 | Faster string searching (Boyer-Moore et al.) | Y | Library Fundamentals TS |
N3915 | apply() call a function with arguments from a tuple | Y | Library Fundamentals TS |
N3916 | Polymorphic memory resources | Partial (missing pool resource and buffer resource classes) | Library Fundamentals TS |
N3920 | Extending shared_ptr to support arrays | Y | Library Fundamentals TS |
N3921 | string_view : a non-owning reference to a string | Y | Library Fundamentals TS |
N3925 | A sample proposal | Y | Library Fundamentals TS |
N3932 | Variable Templates For Type Traits | Y | Library Fundamentals TS |
N4100 | File System | Y |
Link with
-lstdc++fs
|
In this implementation the -std=gnu++17
or
-std=c++17
flag must be used to enable language
and library
features. See dialect
options. The pre-defined symbol
__cplusplus
is used to check for the
presence of the required flag.
This section describes the C++17 and library TS support in mainline GCC, not in any particular release.
The following table lists new library features that are included in the C++17 standard. The "Proposal" column provides a link to the ISO C++ committee proposal that describes the feature, while the "Status" column indicates the first version of GCC that contains an implementation of this feature (if it has been implemented). The "SD-6 Feature Test" column shows the corresponding macro or header from SD-6: Feature-testing recommendations for C++.
Table 1.5. C++ 2017 Library Features
Library Feature | Proposal | Status | SD-6 Feature Test |
---|---|---|---|
constexpr std::hardware_{constructive,destructive}_interference_size
| P0154R1 | No | __cpp_lib_hardware_interference_size >= 201603 |
Core Issue 1776: Replacement of class objects containing reference members | P0137R1 | 7.1 | __cpp_lib_launder >= 201606 |
Wording for std::uncaught_exceptions | N4259 | 6.1 | __cpp_lib_uncaught_exceptions >= 201411 |
C++17 should refer to C11 instead of C99 | P0063R3 | 9.1 | |
Variant: a type-safe union for C++17 | P0088R3 | 7.1 | __has_include(<variant>) ,
__cpp_lib_variant >= 201603
(since 7.3, see Note 1)
|
Library Fundamentals V1 TS Components: optional | P0220R1 | 7.1 | __has_include(<optional>) ,
__cpp_lib_optional >= 201603
(since 7.3, see Note 1)
|
Library Fundamentals V1 TS Components: any | P0220R1 | 7.1 | __has_include(<any>) ,
__cpp_lib_any >= 201603
(since 7.3, see Note 1)
|
Library Fundamentals V1 TS Components: string_view | P0220R1 | 7.1 | __has_include(<string_view>) ,
__cpp_lib_string_view >= 201603
(since 7.3, see Note 1)
|
Library Fundamentals V1 TS Components: memory_resource | P0220R1 | 9.1 | __has_include(<memory_resource>) ,
__cpp_lib_memory_resource >= 201603
|
Library Fundamentals V1 TS Components: apply | P0220R1 | 7.1 | __cpp_lib_apply >= 201603 |
Library Fundamentals V1 TS Components: shared_ptr<T[]> | P0220R1 | 7.1 | __cpp_lib_shared_ptr_arrays >= 201603 |
Library Fundamentals V1 TS Components: Searchers | P0220R1 | 7.1 | __cpp_lib_boyer_moore_searcher >= 201603 |
Library Fundamentals V1 TS Components: Sampling | P0220R1 | 7.1 | __cpp_lib_sample >= 201603 |
Constant View: A proposal for a std::as_const helper function template | P0007R1 | 7.1 | __cpp_lib_as_const >= 201510 |
Improving pair and tuple | N4387 | 6.1 | N/A |
make_from_tuple : apply for construction | P0209R2 | 7.1 | __cpp_lib_make_from_tuple >= 201606 |
Removing auto_ptr , random_shuffle() ,
And Old <functional> Stuff
| N4190 | No (kept for backwards compatibility) | |
Deprecating Vestigial Library Parts in C++17 | P0174R2 | No (kept for backwards compatibility) | |
Making std::owner_less more flexible | P0074R0 | 7.1 | __cpp_lib_transparent_operators >= 201510 |
std::addressof should be constexpr | LWG2296 | 7.1 | __cpp_lib_addressof_constexpr >= 201603 |
Safe conversions in unique_ptr<T[]> | N4089 | 6 | |
LWG 2228: Missing SFINAE rule in unique_ptr templated assignment | N4366 | 6 | |
Re-enabling shared_from_this | P0033R1 | 7.1 | __cpp_lib_enable_shared_from_this >= 201603 |
A proposal to add invoke function template | N4169 | 6.1 | __cpp_lib_invoke >= 201411 |
TriviallyCopyable reference_wrapper | N4277 | 5.1 | |
Adopt not_fn from Library Fundamentals 2 for C++17 | P0005R4 | 7.1 | __cpp_lib_not_fn >= 201603 |
Fixes for not_fn | P0358R1 | 7.1 | |
Fixing a design mistake in the searchers interface in Library Fundamentals | P0253R1 | 7.1 | |
Extending memory management tools | P0040R3 | 7.1 | __cpp_lib_raw_memory_algorithms >= 201606L |
shared_ptr::weak_type | P0163R0 | 7.1 | __cpp_lib_shared_ptr_weak_type >= 201606 |
Transformation Trait Alias void_t | N3911 | 6.1 | __cpp_lib_void_t >= 201411 |
Wording for bool_constant , revision 1 | N4389 | 6.1 | __cpp_lib_bool_constant >= 201505 |
Adopt Type Traits Variable Templates from Library Fundamentals TS for C++17 | P0006R0 | 7.1 | __cpp_lib_type_trait_variable_templates >= 201510 |
Logical Operator Type Traits | P0013R1 | 6.1 | __cpp_lib_logical_traits >= 201510 |
Adding [nothrow-]swappable traits | P0185R1 | 7 (__is_swappable available since 6.1) | __cpp_lib_is_swappable >= 201603 |
is_callable , the missing INVOKE related trait | P0077R2 | 7.1 | __cpp_lib_is_invocable >= 201703 |
has_unique_object_representations | P0258R2 | 7.1 | __cpp_lib_has_unique_object_representations >= 201606 |
Polishing <chrono> | P0092R1 | 7.1 | __cpp_lib_chrono >= 201510 |
Adding more constexpr to <chrono> | P0505R0 | 7.1 | __cpp_lib_chrono >= 201611
(since 7.3, see Note 2)
|
Constexpr for std::char_traits | P0426R1 | 8.1 | __cpp_lib_constexpr_char_traits >= 201611 |
Integrating std::string_view and std::string | P0254R2 | 7.1 | |
Give 'std::string' a non-const '.data()' member function | P0272R1 | 7.1 | |
Cleaning-up noexcept in the Library | N4258 | 6.1 | __cpp_lib_allocator_traits_is_always_equal >= 201411 |
Contiguous Iterators | N4284 | N/A | |
Minimal incomplete type support for standard containers | N4510 | 3.0 | __cpp_lib_incomplete_container_elements >= 201505
(since 6.2, see Note 2)
|
Emplace return type | P0084R2 | 7.1 | |
Improved insertion interface for unique-key maps | N4279 | 6.1 | __cpp_lib_map_try_emplace >= 201411 ,
__cpp_lib_unordered_map_try_emplace >= 201411
|
Splicing Maps and Sets | P0083R3 | 7.1 | __cpp_lib_node_extract >= 201606 |
Non-member size() and more | N4280 | 6.1 | __cpp_lib_nonmember_container_access >= 201411 |
A Proposal to Add Constexpr Modifiers to reverse_iterator , move_iterator , array and Range Access | P0031R0 | 7.1 | __cpp_lib_array_constexpr >= 201603 |
The Parallelism TS Should be Standardized | P0024R2 | 9.1 | __has_include(<execution>) ,
__cpp_lib_execution >= 201603 ,
__cpp_lib_parallel_algorithm >= 201603
(requires linking with -ltbb , see Note 3)
|
An algorithm to "clamp" a value between a pair of boundary values | P0025R0 | 7.1 | __cpp_lib_clamp >= 201603 |
Adopt Selected Library Fundamentals V2 Components for C++17 | P0295R0 | 7.1 | __cpp_lib_gcd_lcm >= 201606 |
Proposal to Introduce a 3-Argument Overload to std::hypot | P0030R1 | 7.1 | __cpp_lib_hypot >= 201603 |
Mathematical Special Functions for C++17 | P0226R1 | 7.1 | __cpp_lib_math_special_functions >= 201603
(see Note 4)
|
Adopt the File System TS for C++17 | P0218R1 | 8.1 | __has_include(<filesystem>) ,
__cpp_lib_filesystem >= 201603
(GCC 8.x requires linking with -lstdc++fs )
|
Relative Paths for Filesystem | P0219R1 | 8.1 | __cpp_lib_filesystem >= 201606 |
Adapting string_view by filesystem paths | P0392R0 | 8.1 | __cpp_lib_filesystem >= 201606 |
Directory Entry Caching for Filesystem | P0317R1 | 8.1 | __cpp_lib_filesystem >= 201703 |
constexpr atomic<T>::is_always_lock_free | P0152R1 | 7.1 | __cpp_lib_atomic_is_always_lock_free >= 201603 |
A proposal to add shared_mutex (untimed) (Revision 4) | N4508 | 6.1 | __cpp_lib_shared_mutex >= 201505 |
Variadic lock_guard (Rev. 5) | P0156R2 | 7.1 | __cpp_lib_scoped_lock >= 201703 |
A byte type definition | P0298R3 | 7.1 | __cpp_lib_byte >= 201603 (since 7.3, see Note 2)
|
Elementary string conversions | P0067R5 | 8.1 (only integral types supported) | __has_include(<charconv>)
__cpp_lib_to_chars >= 201611 |
Homogeneous interface for variant, any and optional | P0032R3 | 7.1 |
__cpp_lib_any >= 201606 ,
__cpp_lib_optional >= 201606 ,
__cpp_lib_variant >= 201606
|
Making Optional Greater Equal Again | P0307R2 | 7.1 | __cpp_lib_optional >= 201606 |
Note 1: This feature is supported in GCC 7.1 and 7.2 but before GCC 7.3 the
__cpp_lib
macro is not defined, and compilation will fail if the
header is included without using -std
to enable C++17 support.
Note 2: This feature is supported in older releases but the
__cpp_lib
macro is not defined to the right value
(or not defined at all) until the version shown in parentheses.
Note 3: The Parallel Algorithms have an external dependency on Intel TBB 2018
or later. If the <execution>
header is included then -ltbb
must be used to link to TBB.
Note 4: The mathematical special functions are enabled in C++17 mode from
GCC 7.1 onwards. For GCC 6.x or for C++11/C++14 define
__STDCPP_WANT_MATH_SPEC_FUNCS__
to a non-zero value
and test for __STDCPP_MATH_SPEC_FUNCS__ >= 201003L
.
The following status table is based on the table of contents of ISO/IEC 14882:2017. Some subclauses are not shown in the table where the content is unchanged since C++14 and the implementation is complete.
Table 1.6. C++ 2017 Implementation Status
Section | Description | Status | Comments | |
---|---|---|---|---|
21 | Language support | |||
21.1 | General | |||
21.2 | Common definitions | |||
21.3 | Implementation properties | |||
21.3.1 | General | |||
21.3.2 | Header <limits> synopsis | |||
21.3.3 | Floating-point type properties | |||
21.3.3.1 | float_round_style | N | ||
21.3.3.2 | float_denorm_style | N | ||
21.3.4 | Class template numeric_limits | Y | ||
21.3.5 | Header <climits> synopsis | Y | ||
21.3.6 | Header <cfloat> synopsis | Y | ||
21.4 | Integer types | |||
21.4.1 | Header <cstdint> synopsis | Y | ||
21.5 | Start and termination | Partial | C library dependency for quick_exit, at_quick_exit | |
21.6 | Dynamic memory management | |||
21.6.1 | Header <new> synopsis | |||
21.6.2 | Storage allocation and deallocation | Y | ||
21.6.3 | Storage allocation errors | Y | ||
21.6.4 | Pointer optimization barrier | Y | ||
21.6.5 | Hardware interference size | N | ||
21.7 | Type identification | Y | ||
21.8 | Exception handling | |||
21.8.1 | Header <exception> synopsis | |||
21.8.2 | Class exception | Y | ||
21.8.3 | Class bad_exception | Y | ||
21.8.4 | Abnormal termination | Y | ||
21.8.5 | uncaught_exceptions | Y | ||
21.8.6 | Exception Propagation | Y | ||
21.8.7 | nested_exception | Y | ||
21.9 | Initializer lists | Y | ||
21.10 | Other runtime support | Y | ||
22 | Diagnostics | |||
22.1 | General | |||
22.2 | Exception classes | Y | ||
22.3 | Assertions | Y | ||
22.4 | Error numbers | Y | ||
22.5 | System error support | |||
23 | General utilities | |||
23.1 | General | |||
23.2 | Utility components | |||
23.2.1 | Header <utility> synopsis | |||
23.2.2 | Operators | Y | ||
23.2.3 | swap | Y | ||
23.2.4 | exchange | Y | ||
23.2.5 | Forward/move helpers | Y | ||
23.2.6 | Function template as_const | Y | ||
23.2.7 | Function template declval | Y | ||
23.2.8 | Primitive numeric output conversion | Partial | Only integer types supported, not floating-point types | |
23.2.9 | Primitive numeric input conversion | Partial | Only integer types supported, not floating-point types | |
23.3 | Compile-time integer sequences | |||
23.4 | Pairs | Y | ||
23.5 | Tuples | Y | ||
23.6 | Optional objects | Y | ||
23.7 | Variants | Y | ||
23.8 | Storage for any type | Y | ||
23.9 | Bitsets | Y | ||
23.10 | Memory | Y | ||
23.10.1 | In general | |||
23.10.2 | Header <memory> synopsis | Y | ||
23.10.3 | Pointer traits | Y | ||
23.10.4 | Pointer safety | Y | ||
23.10.5 | Align | Y | ||
23.10.6 | Allocator argument tag | Y | ||
23.10.7 | uses_allocator | Y | ||
23.10.8 | Allocator traits | Y | ||
23.10.9 | The default allocator | Y | ||
23.10.10 | Specialized algorithms | Y | ||
23.10.11 | C library memory allocation | Y | ||
23.11 | Smart pointers | |||
23.11.1 | Class template unique_ptr | Y | ||
23.11.2 | Shared-ownership pointers | Y | ||
23.12 | Memory resources | |||
23.12.1 | Header <memory_resource> synopsis | Y | ||
23.12.2 | Class memory_resource | Y | ||
23.12.3 | Class template polymorphic_allocator | Y | ||
23.12.4 | Access to program-wide memory_resource objects | Y | ||
23.12.5 | Pool resource classes | Y | ||
23.12.6 | Class monotonic_buffer_resource | Y | ||
23.13 | Class template scoped_allocator_adaptor | Y | ||
23.14 | Function objects | |||
23.14.1 | Header <functional> synopsis | |||
23.14.2 | Definitions | |||
23.14.3 | Requirements | |||
23.14.4 | Function template invoke | Y | ||
23.14.5 | Class template reference_wrapper | Y | ||
23.14.6 | Arithmetic operation | Y | ||
23.14.7 | Comparisons | Y | ||
23.14.8 | Logical operations | Y | ||
23.14.9 | Bitwise operations | Y | ||
23.14.10 | Function template not_fn | Y | ||
23.14.11 | Function object binders | Y | ||
23.14.12 | Function template mem_fn | Y | ||
23.14.13 | Polymorphic function wrappers | Y | ||
23.14.14 | Searchers | Y | ||
23.14.15 | Class template hash | Y | ||
23.15 | Metaprogramming and type traits | |||
23.15.1 | Requirements | |||
23.15.2 | Header <type_traits> synopsis | Y | ||
23.15.3 | Helper classes | Y | ||
23.15.4 | Unary Type Traits | Y | ||
23.15.5 | Type property queries | Y | ||
23.15.6 | Relationships between types | Y | ||
23.15.7 | Transformations between types | Y | ||
23.15.8 | Logical operator traits | Y | ||
23.16 | Compile-time rational arithmetic | Y | ||
23.17.1 | In general | |||
23.17.2 | Header <chrono> synopsis | |||
23.17 | Time utilities | |||
23.17.3 | Clock requirements | Y | ||
23.17.4 | Time-related traits | Y | ||
23.17.5 | Class template duration | Y | ||
23.17.6 | Class template time_point | Y | ||
23.17.7 | Clocks | Y | ||
23.17.8 | Header <ctime> synopsis | Y | ||
23.18 | Class type_index | Y | ||
23.19 | Execution policies | |||
23.19.1 | In general | |||
23.19.2 | Header <execution> synopsis | |||
23.19.3 | Execution policy type trait | Y | ||
23.19.4 | Sequenced execution policy | Y | ||
23.19.5 | Parallel execution policy | Y | ||
23.19.6 | Parallel and unsequenced execution policy | Y | ||
23.19.7 | Execution policy objects | Y | ||
24 | Strings | |||
24.1 | General | |||
24.2 | Character traits | Y | ||
24.3 | String classes | Y | ||
24.4 | String view classes | Y | ||
24.4.1 | Header <string_view> synopsis | Y | ||
24.4.2 | Class template basic_string_view | Y | ||
24.4.3 | Non-member comparison functions | Y | ||
24.4.4 | Inserters and extractors | Y | ||
24.4.5 | Hash support | Y | ||
24.4.6 | Suffix for basic_string_view literals | Y | ||
24.5 | Null-terminated sequence utilities | Partial | C library dependency. | |
25 | Localization | |||
25.1 | General | Y | ||
25.2 | Header <locale> synopsis | Y | ||
25.3 | Locales | Y | ||
25.4 | Standard locale categories | Y | ||
25.5 | C Library Locales | Y | ||
26 | Containers | |||
26.1 | General | |||
26.2 | Container requirements | Y | ||
26.3 | Sequence containers | Y | ||
26.4 | Associative containers | Y | ||
26.5 | Unordered associative containers | Y | ||
26.6 | Container adaptors | Y | ||
27 | Iterators | |||
27.1 | General | Y | ||
27.2 | Iterator requirements | Y | ||
27.3 | Header <iterator> synopsis | Y | ||
27.4 | Iterator primitives | Y | ||
27.5 | Iterator adaptors | Y | ||
27.6 | Stream iterators | Y | ||
27.7 | Range access | Y | ||
27.8 | Container access | Y | ||
28 | Algorithms | |||
28.1 | General | |||
28.2 | Header <algorithm> synopsis | |||
28.3 | Algorithms requirements | |||
28.4 | Parallel algorithms | Using PSTL | ||
28.5 | Non-modifying sequence operations | Y | ||
28.6 | Mutating sequence operations | Y | ||
28.7 | Sorting and related operations | Y | ||
28.8 | C library algorithms | Y | ||
29 | Numerics | |||
29.1 | General | |||
29.2 | Definitions | |||
29.3 | Numeric type requirements | Y | ||
29.4 | The floating-point environment | Y | ||
29.5 | Complex numbers | Y | ||
29.6 | Random number generation | Y | ||
29.7 | Numeric arrays | Y | ||
29.8 | Generalized numeric operations | |||
29.8.1 | Header <numeric> synopsis | |||
29.8.2 | Accumulate | Y | ||
29.8.3 | Reduce | Y | ||
29.8.4 | Inner product | Y | ||
29.8.5 | Transform reduce | Y | ||
29.8.6 | Partial sum | Y | ||
29.8.7 | Exclusive scan | Y | ||
29.8.8 | Inclusive scan | Y | ||
29.8.9 | Transform exclusive scan | Y | ||
29.8.10 | Transform inclusive scan | Y | ||
29.8.11 | Adjacent difference | Y | ||
29.8.12 | Iota | Y | ||
29.8.13 | Greatest common divisor | Y | ||
29.8.14 | Least common multiple | Y | ||
29.9 | Mathematical functions for floating-point types | |||
29.9.1 | Header <cmath> synopsis | |||
29.9.2 | Absolute values | Y | ||
29.9.3 | Three-dimensional hypotenuse | Y | ||
29.9.4 | Classification / comparison functions | Y | ||
29.9.5 | Mathematical special functions | Y | ||
30 | Input/output library | |||
30.1 | General | Y | ||
30.2 | Iostreams requirements | Y | ||
30.2.1 | Imbue Limitations | Y | ||
30.2.2 | Positioning Type Limitations | Y | ||
30.2.3 | Thread safety | Partial | ||
30.3 | Forward declarations | Y | ||
30.4 | Standard iostream objects | Y | ||
30.5 | Iostreams base classes | Y | ||
30.6 | Stream buffers | Y | ||
30.7 | Formatting and manipulators | Y | ||
30.8 | String-based streams | Y | ||
30.9 | File-based streams | Y | ||
30.10 | File systemss | Y | ||
30.11 | C library files | Y | ||
31 | Regular expressions | |||
31.1 | General | Y | ||
31.2 | Definitions | Y | ||
31.3 | Requirements | Y | ||
31.4 | Header <regex> synopsis | Y | ||
31.5 | Namespace std::regex_constants | Y | ||
31.6 | Class regex_error | Y | ||
31.7 | Class template regex_traits | Partial | transform_primary is not correctly implemented | |
31.8 | Class template basic_regex | Y | ||
31.9 | Class template sub_match | Y | ||
31.10 | Class template match_results | Y | ||
31.11 | Regular expression algorithms | Y | ||
31.12 | Regular expression Iterators | Y | ||
31.13 | Modified ECMAScript regular expression grammar | Y | ||
32 | Atomic operations | |||
32.1 | General | Y | ||
32.2 | Header <atomic> synopsis | Y | ||
32.3 | Type aliases | Y | ||
32.4 | Order and consistency | Y | ||
32.5 | Lock-free property | Y | ||
32.6 | Class template <atomic> | Y | ||
32.7 | Non-member functions | Y | ||
32.8 | Flag Type and operations | Y | ||
32.9 | Fences | Y | ||
33 | Thread support | |||
33.1 | General | Y | ||
33.2 | Requirements | Y | ||
33.3 | Threads | |||
33.3.1 | Header thread synopsis | |||
33.3.2 | Class thread | Y | ||
33.3.2.1 | Class thread | Partial | thread::id comparisons not well-defined | |
33.3.3 | Namespace this_thread | Y | ||
33.4 | Mutual exclusion | |||
33.4.3 | Mutex requirements | |||
33.4.3.1 | In general | |||
33.4.3.2 | Mutex types | |||
33.4.3.2.1 | Class mutex | Y | ||
33.4.3.2.2 | Class recursive_mutex | Y | ||
33.4.3.3 | Timed mutex types | |||
33.4.3.3.1 | Class timed_mutex | Y | ||
33.4.3.3.2 | Class recursive_timed_mutex | Y | ||
33.4.3.4 | Shared mutex types | |||
33.4.3.4.1 | Class shared_mutex | Y | ||
33.4.3.5 | Shared timed mutex types | |||
33.4.3.5.1 | Class shared_timed_mutex | Y | ||
33.4.4 | Locks | |||
33.4.4.1 | Class template lock_guard | Y | ||
33.4.4.2 | Class template scoped_guard | Y | ||
33.4.4.3 | Class template unique_lock | Y | ||
33.4.4.4 | Class template shared_lock | Y | ||
33.4.5 | Generic locking algorithms | Y | ||
33.4.6 | Call once | |||
33.4.6.1 | Struct once_flag | Y | ||
33.4.6.2 | Function call_once | Broken | See PR 66146 | |
33.5 | Condition variables | Y | ||
33.5.1 | Class condition_variable | Y | ||
33.5.2 | Class condition_variable_any | Y | ||
33.6 | Futures | |||
33.6.1 | Overview | |||
33.6.2 | Header <future> | |||
33.6.3 | Error handling | Y | ||
33.6.4 | Class future_error | Y | ||
33.6.5 | Shared state | Y | ||
33.6.6 | Class template promise | Y | ||
33.6.7 | Class template future | Y | ||
33.6.8 | Class template shared_future | Y | ||
33.6.9 | Function template async | Y | ||
33.6.10 | Class template packaged_task | Y | ||
Appendix D | Compatibility features | |||
D.4 | C++ standard library headers | Y | ||
D.4.1 | Header <ccomplex> synopsis | Y | ||
D.4.1 | Header <cstdalign> synopsis | Y | ||
D.4.1 | Header <cstdbool> synopsis | Y | ||
D.4.1 | Header <ctgmath> synopsis | Y | ||
D.5 | C standard library headers | Y | ||
D.6 | char* streams | Y | ||
D.7 | uncaught_exception | Y | ||
D.8 | Old adaptable function bindings | Y | ||
D.9 | The default allocator | Y | ||
D.10 | Raw storage iterator | Y | ||
D.11 | Temporary buffers | Y | ||
D.12 | Deprecated type traits | Y | ||
D.13 | Deprecated iterator primitives | Y | ||
D.14 | Deprecated shared_ptr observers | Y | ||
D.15 | Deprecated standard code conversion facets | Y | ||
D.16 | Deprecated convenience conversion interfaces | Y |
Table 1.7. C++ Technical Specifications Implementation Status
Paper | Title | Status | Comments |
---|---|---|---|
N4076 | A generalized callable negator | Y | Library Fundamentals 2 TS |
N4273 | Uniform Container Erasure | Y | Library Fundamentals 2 TS |
N4061 | Greatest Common Divisor and Least Common Multiple | Y | Library Fundamentals 2 TS |
N4066 | Delimited iterators | Y | Library Fundamentals 2 TS |
N4282 | The World's Dumbest Smart Pointer | Y | Library Fundamentals 2 TS |
N4388 | Const-Propagating Wrapper | Y | Library Fundamentals 2 TS |
N4391 | make_array , revision 4 | Y | Library Fundamentals 2 TS |
N4502 | Support for the C++ Detection Idiom, V2 | Y | Library Fundamentals 2 TS |
N4519 | Source-Code Information Capture | Y | Library Fundamentals 2 TS |
N4521 | Merge Fundamentals V1 into V2 |
N (components from V1 are still in namespace
fundamentals_v1 )
| Library Fundamentals 2 TS |
P0013R1 | Logical Operator Type Traits (revision 1) | Y | Library Fundamentals 2 TS |
N4531 | std::rand replacement, revision 3 | Y | Library Fundamentals 2 TS |
For behaviour which is also specified by previous standards, see C++ 1998/2003 Implementation Specific Behavior and C++ 2011 Implementation Specific Behavior. This section only documents behaviour which is new in the 2017 standard.
20.5.1.2 [headers] Whether names from Annex K are declared by C++ headers depends on whether the underlying C library supports Annex K and declares the names. For the GNU C library, there is no Annex K support and so none of its names are declared by C++ headers.
23.6.5 [optional.bad_optional_access]
what()
returns "bad optional access"
.
23.7.3 [variant.variant]
variant
supports over-aligned types.
23.7.10 [variant.bad.access]
what()
returns one of the strings
"std::get: variant is valueless"
,
"std::get: wrong index for variant"
,
"std::visit: variant is valueless"
,
or "std::visit<R>: variant is valueless"
.
23.12.5.2 [memory.resource.pool.options]
Let S equal numeric_limits<size_t>::digits
.
The limit for maximum number of blocks in a chunk is given by
2N-1,
where N is min(19, 3 + S/2).
The largest allocation size that will be allocated from a pool is
222
when S > 20,
otherwise 3072 when S > 16,
otherwise 768.
23.12.6.1 [memory.resource.monotonic.buffer.ctor]
The default next_buffer_size
is 128 * sizeof(void*)
.
The default growth factor is 1.5
.
23.15.4.3 [meta.unary.prop]
The predicate condition for
has_unique_object_representations
is true for all scalar
types except floating point types.
23.19.3 [execpol.type], 28.4.3 [algorithms.parallel.exec] There are no implementation-defined execution policies.
24.4.2 [string.view.template]
basic_string_view<C, T>::iterator
is
C*
and
basic_string_view<C, T>::const_iterator
is
const C*
.
28.4.3 [algorithms.parallel.exec]
Threads of execution created by std::thread
provide concurrent forward progress guarantees, so threads of execution
implicitly created by the library will provide parallel forward
progress guarantees.
29.4.1 [cfenv.syn]
The effects of the <cfenv>
functions
depends on whether the FENV_ACCESS
pragma is supported,
and on the C library that provides the header.
29.6.9 [c.math.rand]
Whether the rand
function may introduce data
races depends on the target C library that provides the function.
29.9.5 [sf.cmath] The effect of calling the mathematical special functions with large inputs should be documented here.
30.10.2.1 [fs.conform.9945] The behavior of the filesystem library implementation will depend on the target operating system. Some features will not be supported on some targets.
30.10.5 [fs.filesystem.syn] The clock used for file times is an unspecified type with a signed 64-bit representation, capable of representing timestamps with nanosecond resolution. The clock's epoch is unspecified, but is not the same as the system clock's epoch.
30.10.7.1 [fs.path.generic]
dot-dot in the root-directory refers to the root-directory itself.
On Windows, a drive specifier such as "C:"
or
"z:"
is treated as a root-name. On Cygwin, a path
that begins with two successive directory separators is a
root-name. Otherwise (for POSIX-like systems other than Cygwin),
the implementation-defined root-name is an unspecified string
which does not appear in any pathnames.
30.10.10.1 [fs.enum.path.format] The character sequence is always interpreted in the native pathname format.
30.10.15.4 [fs.op.file_size]
If !is_regular_file(p)
, an error is reported.
In this implementation the -std=gnu++2a
or
-std=c++2a
flag must be used to enable language
and library
features. See dialect
options. The pre-defined symbol
__cplusplus
is used to check for the
presence of the required flag.
This section describes the C++20 and library TS support in mainline GCC, not in any particular release.
The following table lists new library features that have been accepted into the C++20 working draft. The "Proposal" column provides a link to the ISO C++ committee proposal that describes the feature, while the "Status" column indicates the first version of GCC that contains an implementation of this feature (if it has been implemented). A dash (—) in the status column indicates that the changes in the proposal either do not affect the code in libstdc++, or the changes are not required for conformance. The "SD-6 Feature Test / Notes" column shows the corresponding macro or header from SD-6: Feature-testing recommendations for C++ (where applicable) or any notes about the implementation.
Table 1.8. C++ 2020 Library Features
Library Feature | Proposal | Status | SD-6 Feature Test / Notes | ||||||
---|---|---|---|---|---|---|---|---|---|
Compile-time programming | |||||||||
Add constexpr modifiers to functions in <algorithm> and <utility> Headers | P0202R3 | 10.1 | __cpp_lib_constexpr_algorithms >= 201703L | ||||||
Constexpr for swap and swap related functions | P0879R0 | 10.1 | __cpp_lib_constexpr_algorithms >= 201806L | ||||||
Constexpr for std::complex | P0415R1 | 9.1 | __cpp_lib_constexpr_complex >= 201711L (since 9.4, see Note 1) | ||||||
P0595R2 std::is_constant_evaluated() | P0595R2 | 9.1 | __cpp_lib_is_constant_evaluated >= 201811L | ||||||
More constexpr containers | P0784R7 | 10.1 | __cpp_lib_constexpr_dynamic_alloc >= 201907L | ||||||
Making std::string constexpr | P0980R1 | __cpp_lib_constexpr_string >= 201907L | |||||||
Making std::vector constexpr | P1004R2 | __cpp_lib_constexpr_vector >= 201907L | |||||||
Constexpr in std::pointer_traits | P1006R1 | 9.1 | __cpp_lib_constexpr_memory >= 201811L (since 9.4, see Note 1) | ||||||
constexpr for <numeric> algorithms | P1645R1 | 10.1 | __cpp_lib_constexpr_numeric >= 201911L | ||||||
Constexpr iterator requirements | P0858R0 | 9.1 |
| ||||||
constexpr comparison operators for std::array | P1023R0 | 10.1 | __cpp_lib_array_constexpr >= 201806 | ||||||
Misc constexpr bits | P1032R1 | 10.1 |
| ||||||
constexpr INVOKE | P1065R2 | 10.1 | __cpp_lib_constexpr_functional >= 201907L | ||||||
Transformation Trait remove_cvref | P0550R2 | 9.1 | __cpp_lib_remove_cvref >= 201711L (since 9.4, see Note 1) | ||||||
Implicit conversion traits and utility functions | P0758R1 | 9.1 | __cpp_lib_is_nothrow_convertible >= 201806L (since 9.4, see Note 1) | ||||||
The identity metafunction | P0887R1 | 9.1 | __cpp_lib_type_identity >= 201806L (since 9.4, see Note 1) | ||||||
unwrap_ref_decay and unwrap_reference | P0318R1 | 9.1 | __cpp_lib_unwrap_ref >= 201811L (since 9.4, see Note 1) | ||||||
Improving Completeness Requirements for Type Traits | P1285R0 | Partial | |||||||
Missing feature test macros | P1353R0 | 9.1 | |||||||
Making std::underlying_type SFINAE-friendly | P0340R3 | 9.1 | |||||||
Traits for [Un]bounded Arrays | P1357R1 | 9.1 | __cpp_lib_bounded_array_traits >= 201902L | ||||||
Layout-compatibility and pointer-interconvertibility traits | P0466R5 |
| |||||||
Integrating feature-test macros into the C++ WD | P0941R2 | 5.1 | |||||||
<version> | P0754R2 | 9.1 | __has_include(<version>) | ||||||
Synchronization | |||||||||
Atomic Ref | P0019R8 | 10.1 | __cpp_lib_atomic_ref >= 201806L | ||||||
Floating Point Atomic | P0020R6 | 10.1 | __cpp_lib_atomic_float >= 201711L | ||||||
C++ Synchronized Buffered Ostream | P0053R7 | __cpp_lib_syncbuf >= 201711L | |||||||
Manipulators for C++ Synchronized Buffered Ostream | P0753R2 | __cpp_lib_syncbuf >= 201803L | |||||||
Make std::memory_order a scoped enumeration | P0439R0 | 9.1 | |||||||
The Curious Case of Padding Bits, Featuring Atomic Compare-and-Exchange | P0528R3 | ||||||||
Atomic shared_ptr | P0718R2 | __cpp_lib_atomic_shared_ptr >= 201711L | |||||||
std::stop_token and std::jthread | P0660R10 | 10.1 | __cpp_lib_jthread >= 201907L | ||||||
Rename condition_variable_any interruptible wait methods | P1869R1 | 10.1 | __cpp_lib_jthread >= 201911L | ||||||
Atomic waiting and notifying, std::semaphore, std::latch and std::barrier | P1135R6 |
| |||||||
Fixing Atomic Initialization | P0883R2 | 10.1 | __cpp_lib_atomic_value_initialization >= 201911L | ||||||
Ranges and Concepts | |||||||||
Standard Library Concepts | P0898R3 | 10.1 | __cpp_lib_concepts >= 201806L | ||||||
Rename concepts to standard_case for C++20, while we still can | P1754R1 | 10.1 | __cpp_lib_concepts >= 201907L | ||||||
Wording for boolean-testable | P1964R2 | 10.1 | __cpp_lib_concepts >= 202002L | ||||||
The One Ranges Proposal | P0896R4 | 10.1 | __cpp_lib_ranges >= 201811L | ||||||
Input Range Adaptors | P1035R7 | 10.1 | __cpp_lib_ranges >= 201907L | ||||||
ranges compare algorithm are over-constrained | P1716R3 | 10.1 | __cpp_lib_ranges >= 201911L | ||||||
Remove CommonReference requirement from StrictWeakOrdering (a.k.a Fixing Relations) | P1248R1 | 10.1 | |||||||
Ranges Design Cleanup | P1252R2 | 10.1 | |||||||
Time, dates, calendars, time zones | |||||||||
Extending chrono to Calendars and Time Zones | P0355R7 | __cpp_lib_chrono >= 201803L | |||||||
Miscellaneous minor fixes for chrono | P1466R3 | __cpp_lib_chrono >= 201907L | |||||||
<chrono> zero() , min() , and max() should be noexcept | P0972R0 | 9.1 | |||||||
Three-way comparison | |||||||||
Library Support for the Spaceship (Comparison) Operator | P0768R1 | 10.1 | __cpp_lib_three_way_comparison >= 201711L | ||||||
Symmetry for spaceship | P0905R1 | 10.1 | |||||||
Adding <=> to the standard library | P1614R2 | 10.1 |
__cpp_lib_three_way_comparison >= 201907L
| ||||||
Strings and text | |||||||||
string::reserve Should Not Shrink | P0966R1 | ||||||||
char8_t : A type for UTF-8 characters and strings | P0482R6 | 9.1 | __cpp_lib_char8_t >= 201811L | ||||||
char8_t backward compatibility remediation | P1423R3 | 10.1 | __cpp_lib_char8_t >= 201907L | ||||||
Text formatting | P0645R10 |
__cpp_lib_format >= 201907L
| |||||||
Integration of chrono with text formatting | P1361R2 |
__cpp_lib_format >= 201907L
| |||||||
Printf corner cases in std::format | P1652R1 |
__cpp_lib_format >= 201907L
| |||||||
String Prefix and Suffix Checking | P0457R2 | 9.1 | __cpp_lib_starts_ends_with >= 201711L (since 9.4, see Note 1) | ||||||
Update The Reference To The Unicode Standard | P1025R1 | ||||||||
Containers | |||||||||
span: bounds-safe views for sequences of objects | P0122R7 | 10.1 | __cpp_lib_span >= 201803L | ||||||
Usability Enhancements for std::span
| P1024R3 | 10.1 | __cpp_lib_span >= 201902L | ||||||
Should Span be Regular? | P1085R2 | 10.1 | |||||||
Fixed-size <span> construction from dynamic range | P1976R2 | 10.1 | __cpp_lib_span >= 202002L | ||||||
std::to_array | P0325R4 | 10.1 | __cpp_lib_to_array >= 201907L | ||||||
Checking for Existence of an Element in Associative Containers | P0458R2 | 9.1 | |||||||
Comparing Unordered Containers | P0809R0 | ||||||||
Heterogeneous lookup for unordered containers | P0919R3 | __cpp_lib_generic_unordered_lookup >= 201811 | |||||||
Adopt Consistent Container Erasure from Library Fundamentals 2 for C++20 | P1209R0 | 9.1 | __cpp_lib_erase_if >= 201811L | ||||||
Improving the Return Value of Erase-Like Algorithms | P0646R1 | 9.1 | __cpp_lib_list_remove_return_type >= 201806L | ||||||
Improving the Return Value of Erase-Like Algorithms II: Free erase /erase_if | P1115R3 | 9.1 |
| ||||||
Signed ssize() functions, unsigned size() functions | P1227R2 | 10.1 | __cpp_lib_ssize >= 201902L | ||||||
Memory management | |||||||||
Utility to convert a pointer to a raw pointer | P0653R2 | 8.1 | __cpp_lib_to_address >= 201711L (since 9.4, see Note 1) | ||||||
Extending make_shared to Support Arrays | P0674R1 | __cpp_lib_shared_ptr_arrays >= 201707L | |||||||
Efficient sized delete for variable sized classes | P0722R3 | 9.1 | __cpp_lib_destroying_delete >= 201806L | ||||||
Utility functions to implement uses-allocator construction | P0591R4 | 9.1 |
std::scoped_allocator_adaptor changes missing in 9.1.0
| ||||||
std::assume_aligned | P1007R3 | 9.1 | __cpp_lib_assume_aligned >= 201811L (since 9.4, see Note 1) | ||||||
Smart pointer creation with default initialization | P1020R1 | __cpp_lib_smart_ptr_for_overwrite >= 201811L | |||||||
Make stateful allocator propagation more consistent for operator+(basic_string) | P1165R1 | 10.1 | |||||||
polymorphic_allocator<> as a vocabulary type
| P0339R6 | 9.1 |
__cpp_lib_polymorphic_allocator >= 201902L (since 9.4, see Note 1)
| ||||||
LWG 2511: guaranteed copy elision for piecewise construction | P0475R1 | 7.1 | |||||||
Miscellaneous | |||||||||
nodiscard in the Library | P0600R1 | 9.1 | |||||||
de-pessimize legacy algorithms with std::move | P0616R0 | 9.1 | |||||||
Deprecate POD | P0767R1 | 10.1 | |||||||
Treating Unnecessary decay | P0777R1 | 9.1 | |||||||
Thou Shalt Not Specialize std Function Templates! | P0551R3 | ||||||||
Bit-casting object representations | P0476R2 | __cpp_lib_bit_cast >= 201806L | |||||||
Integral power-of-2 operations | P0556R3 | 9.1 | __cpp_lib_int_pow2 >= 201806L (since 9.4, see Note 1) | ||||||
On the names of low-level bit manipulation functions | P1956R1 | 10.1 | __cpp_lib_int_pow2 >= 202002L | ||||||
Safe integral comparisons | P0586R2 | 10.1 | __cpp_lib_integer_comparison_functions >= 202002L | ||||||
Reviewing Deprecated Facilities of C++17 for C++20 | P0619R4 | ||||||||
fpos Requirements | P0759R1 | — | |||||||
Add shift to <algorithm> | P0769R2 | 10.1 | __cpp_lib_shift >= 201806L | ||||||
Standard Library Specification in a Concepts and Contracts World | P0788R3 | ||||||||
explicit(bool) | P0892R2 | — | |||||||
Eradicating unnecessarily explicit default constructors from the standard library | P0935R0 | 9.1 | |||||||
std::function move constructor should be noexcept | P0771R1 | 7.2 | |||||||
Simplified partial function application | P0356R5 | 9.1 | __cpp_lib_bind_front >= 201811L | ||||||
bind_front should not unwrap reference_wrapper | P1651R0 | 9.3 | __cpp_lib_bind_front >= 201907L | ||||||
reference_wrapper for incomplete types | P0357R3 | 9.1 | |||||||
Fixing operator>>(basic_istream&, CharT*) (LWG 2499) | P0487R1 | ||||||||
variant and optional should propagate copy/move triviality | P0602R4 | 8.3 | |||||||
A sane variant converting constructor | P0608R3 | 10.1 | |||||||
visit<R> : Explicit Return Type for visit | P0655R1 | 9.1 | |||||||
P0899R1 - LWG 3016 is not a defect | P0899R1 | 7.1 | |||||||
Editorial Guidance for merging P0019r8 and P0528r3 | P1123R0 | — | |||||||
Cleaning up Clause 20 | P1148R0 | ||||||||
Completing the Rebase of Library Fundamentals, Version 3, Working Draft | P1210R0 | ||||||||
Alternative Wording for P0907R4 Signed Integers are Two's Complement | P1236R1 | — | |||||||
I Stream, You Stream, We All Stream for
istream_iterator
| P0738R2 | 10.1 | |||||||
Mandating the Standard Library: Clause 16 - Language support library | P1458R1 | — | |||||||
Mandating the Standard Library: Clause 18 - Diagnostics library | P1459R1 | — | |||||||
Mandating the Standard Library: Clause 20 - Strings library | P1462R1 | — | |||||||
Mandating the Standard Library: Clause 21 - Containers library | P1463R1 | 10.1 | |||||||
Mandating the Standard Library: Clause 22 - Iterators library | P1464R1 | ||||||||
Make create_directory() Intuitive | P1164R1 | 8.3 | Treated as a DR for C++17 | ||||||
Target Vectorization Policies from Parallelism V2 TS to C++20 | P1001R2 | 9.1 | __cpp_lib_execution >= 201902L (since 9.4, see Note 1) | ||||||
Merge Coroutines TS into C++20 working draft | P0912R5 | 10.1 | __cpp_lib_coroutines >= 201902L | ||||||
Endian just Endian | P0463R1 | 8.1 | __cpp_lib_endian >= 201907L | ||||||
Bit operations | P0553R4 | 10.1 | __cpp_lib_bitops >= 201907L (since 9.4, see Note 1) | ||||||
Well-behaved interpolation for numbers and pointers | P0811R3 | 9.1 | __cpp_lib_interpolate >= 201902L | ||||||
Mathematical constants | P0631R8 | 10.1 | __cpp_lib_math_constants >= 201907L | ||||||
std::source_location | P1208R6 |
__cpp_lib_source_location >= 201907L
| |||||||
Efficient access to std::basic_stringbuf's Buffer | P0408R7 |
Note 1: This feature is supported in older releases but the
__cpp_lib
macro is not defined to the right value
(or not defined at all) until the version shown in parentheses.
This table is based on the table of contents of ISO/IEC DTR 19768 Doc No: N1836=05-0096 Date: 2005-06-24 Draft Technical Report on C++ Library Extensions
In this implementation the header names are prefixed by
tr1/
, for instance <tr1/functional>
,
<tr1/memory>
, and so on.
This page describes the TR1 support in mainline GCC, not in any particular release.
Table 1.9. C++ TR1 Implementation Status
Section | Description | Status | Comments |
---|---|---|---|
2 | General Utilities | ||
2.1 | Reference wrappers | ||
2.1.1 | Additions to header <functional> synopsis | Y | |
2.1.2 | Class template reference_wrapper | ||
2.1.2.1 | reference_wrapper construct/copy/destroy | Y | |
2.1.2.2 | reference_wrapper assignment | Y | |
2.1.2.3 | reference_wrapper access | Y | |
2.1.2.4 | reference_wrapper invocation | Y | |
2.1.2.5 | reference_wrapper helper functions | Y | |
2.2 | Smart pointers | ||
2.2.1 | Additions to header <memory> synopsis | Y | |
2.2.2 | Class bad_weak_ptr | Y | |
2.2.3 | Class template shared_ptr |
Uses code from boost::shared_ptr. | |
2.2.3.1 | shared_ptr constructors | Y | |
2.2.3.2 | shared_ptr destructor | Y | |
2.2.3.3 | shared_ptr assignment | Y | |
2.2.3.4 | shared_ptr modifiers | Y | |
2.2.3.5 | shared_ptr observers | Y | |
2.2.3.6 | shared_ptr comparison | Y | |
2.2.3.7 | shared_ptr I/O | Y | |
2.2.3.8 | shared_ptr specialized algorithms | Y | |
2.2.3.9 | shared_ptr casts | Y | |
2.2.3.10 | get_deleter | Y | |
2.2.4 | Class template weak_ptr | ||
2.2.4.1 | weak_ptr constructors | Y | |
2.2.4.2 | weak_ptr destructor | Y | |
2.2.4.3 | weak_ptr assignment | Y | |
2.2.4.4 | weak_ptr modifiers | Y | |
2.2.4.5 | weak_ptr observers | Y | |
2.2.4.6 | weak_ptr comparison | Y | |
2.2.4.7 | weak_ptr specialized algorithms | Y | |
2.2.5 | Class template enable_shared_from_this | Y | |
3 | Function Objects | ||
3.1 | Definitions | Y | |
3.2 | Additions to <functional> synopsis | Y | |
3.3 | Requirements | Y | |
3.4 | Function return types | Y | |
3.5 | Function template mem_fn | Y | |
3.6 | Function object binders | ||
3.6.1 | Class template is_bind_expression | Y | |
3.6.2 | Class template is_placeholder | Y | |
3.6.3 | Function template bind | Y | |
3.6.4 | Placeholders | Y | |
3.7 | Polymorphic function wrappers | ||
3.7.1 | Class bad_function_call | Y | |
3.7.1.1 | bad_function_call constructor | Y | |
3.7.2 | Class template function | ||
3.7.2.1 | function construct/copy/destroy | Y | |
3.7.2.2 | function modifiers | Y | |
3.7.2.3 | function capacity | Y | |
3.7.2.4 | function invocation | Y | |
3.7.2.5 | function target access | Y | |
3.7.2.6 | undefined operators | Y | |
3.7.2.7 | null pointer comparison operators | Y | |
3.7.2.8 | specialized algorithms | Y | |
4 | Metaprogramming and type traits | ||
4.1 | Requirements | Y | |
4.2 | Header <type_traits> synopsis | Y | |
4.3 | Helper classes | Y | |
4.4 | General Requirements | Y | |
4.5 | Unary Type Traits | ||
4.5.1 | Primary Type Categories | Y | |
4.5.2 | Composite type traits | Y | |
4.5.3 | Type properties | Y | |
4.6 | Relationships between types | Y | |
4.7 | Transformations between types | ||
4.7.1 | Const-volatile modifications | Y | |
4.7.2 | Reference modifications | Y | |
4.7.3 | Array modifications | Y | |
4.7.4 | Pointer modifications | Y | |
4.8 | Other transformations | Y | |
4.9 | Implementation requirements | Y | |
5 | Numerical Facilities | ||
5.1 | Random number generation | ||
5.1.1 | Requirements | Y | |
5.1.2 | Header <random> synopsis | Y | |
5.1.3 | Class template variate_generator | Y | |
5.1.4 | Random number engine class templates | Y | |
5.1.4.1 | Class template linear_congruential | Y | |
5.1.4.2 | Class template mersenne_twister | Y | |
5.1.4.3 | Class template subtract_with_carry | Y | |
5.1.4.4 | Class template subtract_with_carry_01 | Y | |
5.1.4.5 | Class template discard_block | Y | |
5.1.4.6 | Class template xor_combine | Y | operator()() per N2079 |
5.1.5 | Engines with predefined parameters | Y | |
5.1.6 | Class random_device | Y | |
5.1.7 | Random distribution class templates | Y | |
5.1.7.1 | Class template uniform_int | Y | |
5.1.7.2 | Class bernoulli_distribution | Y | |
5.1.7.3 | Class template geometric_distribution | Y | |
5.1.7.4 | Class template poisson_distribution | Y | |
5.1.7.5 | Class template binomial_distribution | Y | |
5.1.7.6 | Class template uniform_real | Y | |
5.1.7.7 | Class template exponential_distribution | Y | |
5.1.7.8 | Class template normal_distribution | Y | |
5.1.7.9 | Class template gamma_distribution | Y | |
5.2 | Mathematical special functions | Y | |
5.2.1 | Additions to header <cmath> synopsis | Y | |
5.2.1.1 | associated Laguerre polynomials | Y | |
5.2.1.2 | associated Legendre functions | Y | |
5.2.1.3 | beta function | Y | |
5.2.1.4 | (complete) elliptic integral of the first kind | Y | |
5.2.1.5 | (complete) elliptic integral of the second kind | Y | |
5.2.1.6 | (complete) elliptic integral of the third kind | Y | |
5.2.1.7 | confluent hypergeometric functions | Y | |
5.2.1.8 | regular modified cylindrical Bessel functions | Y | |
5.2.1.9 | cylindrical Bessel functions (of the first kind) | Y | |
5.2.1.10 | irregular modified cylindrical Bessel functions | Y | |
5.2.1.11 | cylindrical Neumann functions | Y | |
5.2.1.12 | (incomplete) elliptic integral of the first kind | Y | |
5.2.1.13 | (incomplete) elliptic integral of the second kind | Y | |
5.2.1.14 | (incomplete) elliptic integral of the third kind | Y | |
5.2.1.15 | exponential integral | Y | |
5.2.1.16 | Hermite polynomials | Y | |
5.2.1.17 | hypergeometric functions | Y | |
5.2.1.18 | Laguerre polynomials | Y | |
5.2.1.19 | Legendre polynomials | Y | |
5.2.1.20 | Riemann zeta function | Y | |
5.2.1.21 | spherical Bessel functions (of the first kind) | Y | |
5.2.1.22 | spherical associated Legendre functions | Y | |
5.2.1.23 | spherical Neumann functions | Y | |
5.2.2 | Additions to header <math.h> synopsis | Y | |
6 | Containers | ||
6.1 | Tuple types | Y | |
6.1.1 | Header <tuple> synopsis | Y | |
6.1.2 | Additions to header <utility> synopsis | Y | |
6.1.3 | Class template tuple | Y | |
6.1.3.1 | Construction | Y | |
6.1.3.2 | Tuple creation functions | Y | |
6.1.3.3 | Tuple helper classes | Y | |
6.1.3.4 | Element access | Y | |
6.1.3.5 | Relational operators | Y | |
6.1.4 | Pairs | Y | |
6.2 | Fixed size array | Y | |
6.2.1 | Header <array> synopsis | Y | |
6.2.2 | Class template array | Y | |
6.2.2.1 | array constructors, copy, and assignment | Y | |
6.2.2.2 | array specialized algorithms | Y | |
6.2.2.3 | array size | Y | |
6.2.2.4 | Zero sized array s | Y | |
6.2.2.5 | Tuple interface to class template array | Y | |
6.3 | Unordered associative containers | Y | |
6.3.1 | Unordered associative container requirements | Y | |
6.3.1.1 | Exception safety guarantees | Y | |
6.3.2 | Additions to header <functional> synopsis | Y | |
6.3.3 | Class template hash | Y | |
6.3.4 | Unordered associative container classes | Y | |
6.3.4.1 | Header <unordered_set> synopsis | Y | |
6.3.4.2 | Header <unordered_map> synopsis | Y | |
6.3.4.3 | Class template unordered_set | Y | |
6.3.4.3.1 | unordered_set constructors | Y | |
6.3.4.3.2 | unordered_set swap | Y | |
6.3.4.4 | Class template unordered_map | Y | |
6.3.4.4.1 | unordered_map constructors | Y | |
6.3.4.4.2 | unordered_map element access | Y | |
6.3.4.4.3 | unordered_map swap | Y | |
6.3.4.5 | Class template unordered_multiset | Y | |
6.3.4.5.1 | unordered_multiset constructors | Y | |
6.3.4.5.2 | unordered_multiset swap | Y | |
6.3.4.6 | Class template unordered_multimap | Y | |
6.3.4.6.1 | unordered_multimap constructors | Y | |
6.3.4.6.2 | unordered_multimap swap | Y | |
7 | Regular Expressions | ||
7.1 | Definitions | N | |
7.2 | Requirements | N | |
7.3 | Regular expressions summary | N | |
7.4 | Header <regex> synopsis | N | |
7.5 | Namespace tr1::regex_constants | N | |
7.5.1 | Bitmask Type syntax_option_type | N | |
7.5.2 | Bitmask Type regex_constants::match_flag_type | N | |
7.5.3 | Implementation defined error_type | N | |
7.6 | Class regex_error | N | |
7.7 | Class template regex_traits | N | |
7.8 | Class template basic_regex | N | |
7.8.1 | basic_regex constants | N | |
7.8.2 | basic_regex constructors | N | |
7.8.3 | basic_regex assign | N | |
7.8.4 | basic_regex constant operations | N | |
7.8.5 | basic_regex locale | N | |
7.8.6 | basic_regex swap | N | |
7.8.7 | basic_regex non-member functions | N | |
7.8.7.1 | basic_regex non-member swap | N | |
7.9 | Class template sub_match | N | |
7.9.1 | sub_match members | N | |
7.9.2 | sub_match non-member operators | N | |
7.10 | Class template match_results | N | |
7.10.1 | match_results constructors | N | |
7.10.2 | match_results size | N | |
7.10.3 | match_results element access | N | |
7.10.4 | match_results formatting | N | |
7.10.5 | match_results allocator | N | |
7.10.6 | match_results swap | N | |
7.11 | Regular expression algorithms | N | |
7.11.1 | exceptions | N | |
7.11.2 | regex_match | N | |
7.11.3 | regex_search | N | |
7.11.4 | regex_replace | N | |
7.12 | Regular expression Iterators | N | |
7.12.1 | Class template regex_iterator | N | |
7.12.1.1 | regex_iterator constructors | N | |
7.12.1.2 | regex_iterator comparisons | N | |
7.12.1.3 | regex_iterator dereference | N | |
7.12.1.4 | regex_iterator increment | N | |
7.12.2 | Class template regex_token_iterator | N | |
7.12.2.1 | regex_token_iterator constructors | N | |
7.12.2.2 | regex_token_iterator comparisons | N | |
7.12.2.3 | regex_token_iterator dereference | N | |
7.12.2.4 | regex_token_iterator increment | N | |
7.13 | Modified ECMAScript regular expression grammar | N | |
8 | C Compatibility | ||
8.1 | Additions to header <complex> | Y | |
8.1.1 | Synopsis | Y | |
8.1.2 | Function acos | Y | |
8.1.3 | Function asin | Y | |
8.1.4 | Function atan | Y | |
8.1.5 | Function acosh | Y | |
8.1.6 | Function asinh | Y | |
8.1.7 | Function atanh | Y | |
8.1.8 | Function fabs | Y | |
8.1.9 | Additional Overloads | Y | |
8.2 | Header <ccomplex> | N | DR 551 |
8.3 | Header <complex.h> | N | DR 551 |
8.4 | Additions to header <cctype> | Y | |
8.4.1 | Synopsis | Y | |
8.4.2 | Function isblank | Y | |
8.5 | Additions to header <ctype.h> | Y | |
8.6 | Header <cfenv> | Y | |
8.6.1 | Synopsis | Y | |
8.6.2 | Definitions | Y | |
8.7 | Header <fenv.h> | Y | |
8.8 | Additions to header <cfloat> | Y | |
8.9 | Additions to header <float.h> | Y | |
8.10 | Additions to header <ios> | N | |
8.10.1 | Synopsis | N | |
8.10.2 | Function hexfloat | N | |
8.11 | Header <cinttypes> | Y | |
8.11.1 | Synopsis | Y | DR 557 |
8.11.2 | Definitions | Y | |
8.12 | Header <inttypes.h> | Y | |
8.13 | Additions to header <climits> | Y | |
8.14 | Additions to header <limits.h> | Y | |
8.15 | Additions to header <locale> | N | |
8.16 | Additions to header <cmath> | Y | |
8.16.1 | Synopsis | Y | |
8.16.2 | Definitions | Y | |
8.16.3 | Function template definitions | Y | |
8.16.4 | Additional overloads | Y | DR 568; DR 550 |
8.17 | Additions to header <math.h> | Y | |
8.18 | Additions to header <cstdarg> | Y | |
8.19 | Additions to header <stdarg.h> | Y | |
8.20 | The header <cstdbool> | Y | |
8.21 | The header <stdbool.h> | Y | |
8.22 | The header <cstdint> | Y | |
8.22.1 | Synopsis | Y | |
8.22.2 | Definitions | Y | |
8.23 | The header <stdint.h> | Y | |
8.24 | Additions to header <cstdio> | Y | |
8.24.1 | Synopsis | Y | |
8.24.2 | Definitions | Y | |
8.24.3 | Additional format specifiers | Y | C library dependency |
8.24.4 | Additions to header <stdio.h> | Y | |
8.25 | Additions to header <cstdlib> | Y | |
8.25.1 | Synopsis | Y | |
8.25.2 | Definitions | Y | |
8.25.3 | Function abs | Y | |
8.25.4 | Function div | Y | |
8.26 | Additions to header <stdlib.h> | Y | |
8.27 | Header <ctgmath> | Y | DR 551 |
8.28 | Header <tgmath.h> | Y | DR 551 |
8.29 | Additions to header <ctime> | Y | C library dependency |
8.30 | Additions to header <cwchar> | Y | |
8.30.1 | Synopsis | Y | |
8.30.2 | Definitions | Y | |
8.30.3 | Additional wide format specifiers | Y | C library dependency |
8.31 | Additions to header <wchar.h> | Y | |
8.32 | Additions to header <cwctype> | Y | |
8.32.1 | Synopsis | Y | |
8.32.2 | Function iswblank | Y | |
8.33 | Additions to header <wctype.h> | Y |
For behaviour which is specified by the 1998 and 2003 standards, see C++ 1998/2003 Implementation Specific Behavior. This section documents behaviour which is required by TR1.
3.6.4 [tr.func.bind.place]/1 There are 29
placeholders defined and the placeholder types are
Assignable
.
This table is based on the table of contents of ISO/IEC TR 24733 Date: 2009-08-28 Extension for the programming language C++ to support decimal floating-point arithmetic
This page describes the TR 24733 support in mainline GCC, not in any particular release.
Table 1.10. C++ TR 24733 Implementation Status
Section | Description | Status | Comments |
---|---|---|---|
0 | Introduction | ||
1 | Normative references | ||
2 | Conventions | ||
3 | Decimal floating-point types | ||
3.1 | Characteristics of decimal floating-point types | ||
3.2 | Decimal Types | ||
3.2.1 | Class decimal synopsis | Partial | Missing declarations for formatted input/output; non-conforming extension for functions converting to integral type |
3.2.2 | Class decimal32 | Partial | Missing 3.2.2.5 conversion to integral type; conforming extension for conversion from scalar decimal floating-point |
3.2.3 | Class decimal64 | Partial | Missing 3.2.3.5 conversion to integral type; conforming extension for conversion from scalar decimal floating-point |
3.2.4 | Class decimal128 | Partial | Missing 3.2.4.5 conversion to integral type; conforming extension for conversion from scalar decimal floating-point |
3.2.5 | Initialization from coefficient and exponent | Y | |
3.2.6 | Conversion to generic floating-point type | Y | |
3.2.7 | Unary arithmetic operators | Y | |
3.2.8 | Binary arithmetic operators | Y | |
3.2.9 | Comparison operators | Y | |
3.2.10 | Formatted input | N | |
3.2.11 | Formatted output | N | |
3.3 | Additions to header limits | N | |
3.4 | Headers cfloat and float.h | ||
3.4.2 | Additions to header cfloat synopsis | Y | |
3.4.3 | Additions to header float.h synopsis | N | |
3.4.4 | Maximum finite value | Y | |
3.4.5 | Epsilon | Y | |
3.4.6 | Minimum positive normal value | Y | |
3.4.7 | Minimum positive subnormal value | Y | |
3.4.8 | Evaluation format | Y | |
3.5 | Additions to cfenv and fenv.h | Outside the scope of GCC | |
3.6 | Additions to cmath and math.h | Outside the scope of GCC | |
3.7 | Additions to cstdio and stdio.h | Outside the scope of GCC | |
3.8 | Additions to cstdlib and stdlib.h | Outside the scope of GCC | |
3.9 | Additions to cwchar and wchar.h | Outside the scope of GCC | |
3.10 | Facets | N | |
3.11 | Type traits | N | |
3.12 | Hash functions | N | |
4 | Notes on C compatibility |
This table is based on the table of contents of ISO/IEC FDIS 29124 Doc No: N3060 Date: 2010-03-06 Extensions to the C++ Library to support mathematical special functions
Complete support for IS 29124 is in GCC 6.1 and later releases, when using
at least C++11 (for older releases or C++98/C++03 use TR1 instead).
For C++11 and C++14 the additions to the library are not declared by their
respective headers unless __STDCPP_WANT_MATH_SPEC_FUNCS__
is defined as a macro that expands to a non-zero integer constant.
For C++17 the special functions are always declared (since GCC 7.1).
When the special functions are declared the macro
__STDCPP_MATH_SPEC_FUNCS__
is defined to 201003L
.
In addition to the special functions defined in IS 29124, for
non-strict modes (i.e. -std=gnu++NN
modes) the
hypergeometric functions and confluent hypergeometric functions
from TR1 are also provided, defined in namespace
__gnu_cxx
.
Table 1.11. C++ Special Functions Implementation Status
Section | Description | Status | Comments |
---|---|---|---|
7 | Macro names | Partial | No diagnostic for inconsistent definitions of
__STDCPP_WANT_MATH_SPEC_FUNCS__ |
8 | Mathematical special functions | Y | |
8.1 | Additions to header <cmath> synopsis | Y | |
8.1.1 | associated Laguerre polynomials | Y | |
8.1.2 | associated Legendre functions | Y | |
8.1.3 | beta function | Y | |
8.1.4 | (complete) elliptic integral of the first kind | Y | |
8.1.5 | (complete) elliptic integral of the second kind | Y | |
8.1.6 | (complete) elliptic integral of the third kind | Y | |
8.1.7 | regular modified cylindrical Bessel functions | Y | |
8.1.8 | cylindrical Bessel functions (of the first kind) | Y | |
8.1.9 | irregular modified cylindrical Bessel functions | Y | |
8.1.10 | cylindrical Neumann functions | Y | |
8.1.11 | (incomplete) elliptic integral of the first kind | Y | |
8.1.12 | (incomplete) elliptic integral of the second kind | Y | |
8.1.13 | (incomplete) elliptic integral of the third kind | Y | |
8.1.14 | exponential integral | Y | |
8.1.15 | Hermite polynomials | Y | |
8.1.16 | Laguerre polynomials | Y | |
8.1.17 | Legendre polynomials | Y | |
8.1.18 | Riemann zeta function | Y | |
8.1.19 | spherical Bessel functions (of the first kind) | Y | |
8.1.20 | spherical associated Legendre functions | Y | |
8.1.21 | spherical Neumann functions | Y | |
8.2 | Additions to header <math.h> | Y | |
8.3 | The header <ctgmath> | Partial | Conflicts with C++ 2011 requirements. |
8.4 | The header <tgmath.h> | N | Conflicts with C++ 2011 requirements. |
For behaviour which is specified by the 2011 standard, see C++ 2011 Implementation Specific Behavior. This section documents behaviour which is required by IS 29124.
7.2 [macro.user]/3 /4 The functions declared in
Clause 8 are only declared when
__STDCPP_WANT_MATH_SPEC_FUNCS__ == 1
(or in C++17 mode, for GCC 7.1 and later).
8.1.1 [sf.cmath.Lnm]/1 The effect of calling
these functions with n >= 128
or m >= 128
should be described here.
8.1.2 [sf.cmath.Plm]/3 The effect of calling
these functions with l >= 128
should be described here.
8.1.3 [sf.cmath.I]/3 The effect of calling
these functions with nu >= 128
should be described here.
8.1.8 [sf.cmath.J]/3 The effect of calling
these functions with nu >= 128
should be described here.
8.1.9 [sf.cmath.K]/3 The effect of calling
these functions with nu >= 128
should be described here.
8.1.10 [sf.cmath.N]/3 The effect of calling
these functions with nu >= 128
should be described here.
8.1.15 [sf.cmath.Hn]/3 The effect of calling
these functions with n >= 128
should be described here.
8.1.16 [sf.cmath.Ln]/3 The effect of calling
these functions with n >= 128
should be described here.
8.1.17 [sf.cmath.Pl]/3 The effect of calling
these functions with l >= 128
should be described here.
8.1.19 [sf.cmath.j]/3 The effect of calling
these functions with n >= 128
should be described here.
8.1.20 [sf.cmath.Ylm]/3 The effect of calling
these functions with l >= 128
should be described here.
8.1.21 [sf.cmath.n]/3 The effect of calling
these functions with n >= 128
should be described here.