You are on page 1of 7

Concepts library

<concepts>
Fundamental library concepts
(C++20)

Coroutines library
<coroutine>
Coroutine support library
(C++20)

Utilities library
<any>
std::any class
(C++17)

<bitset> std::bitset class template


<chrono>
C++ time utilites
(C++11)

<compare>
Three-way comparison operator support
(C++20)

Macro (and function) that saves (and jumps) to an execution


<csetjmp>
context
<csignal> Functions and macro constants for signal management
<cstdarg> Handling of variable length argument lists
<cstddef> Standard macros and typedefs
General purpose utilities: program control, dynamic memory
<cstdlib>
allocation, random numbers, sort and search
<ctime> C-style time/date utilites
<expected>
std::expected class template
(C++23)

Function objects, Function invocations, Bind operations and


<functional>
Reference wrappers
<initializer_list>
std::initializer_list class template
(C++11)

<optional>
std::optional class template
(C++17)

<source_location>
Supplies means to obtain source code location
(C++20)

<tuple>
std::tuple class template
(C++11)

<type_traits>
Compile-time type information
(C++11)

<typeindex>
std::type_index
(C++11)

<typeinfo> Runtime type information utilities


<utility> Various utility components
<variant>
std::variant class template
(C++17)

<version> Supplies implementation-dependent library information


(C++20)
Dynamic memory management
<memory> High-level memory management utilities
<memory_resource>
Polymorphic allocators and memory resources
(C++17)

<new> Low-level memory management utilities


<scoped_allocator>
Nested allocator class
(C++11)
Numeric limits
<cfloat> Limits of floating-point types
<cinttypes> Formatting macros, intmax_t and uintmax_t math and
(C++11) conversions

<climits> Limits of integral types


<cstdint>
Fixed-width integer types and limits of other types
(C++11)

<limits> Uniform way to query properties of arithmetic types


<stdfloat>
Optional extended floating-point types
(C++23)
Error handling
Conditionally compiled macro that compares its argument to
<cassert>
zero
<cerrno> Macro containing the last error number
<exception> Exception handling utilities
<stacktrace>
Stacktrace library
(C++23)

<stdexcept> Standard exception objects


<system_error>
Defines std::error_code, a platform-dependent error code
(C++11)

Strings library
<cctype> Functions to determine the category of narrow characters
<charconv>
std::to_chars and std::from_chars
(C++17)

<cstring> Various narrow character string handling functions


<cuchar>
C-style Unicode character conversion functions
(C++11)

<cwchar> Various wide and multibyte string handling functions


<cwctype> Functions to determine the catagory of wide characters
<format>
Formatting library including std::format
(C++20)

<string> std::basic_string class template


<string_view>
std::basic_string_view class template
(C++17)
Containers library
<array>
std::array container
(C++11)

<deque> std::deque container
<flat_map>
std::flat_map and std::flat_multimap container adaptors
(C++23)

<flat_set>
std::flat_set and std::flat_multiset container adaptors
(C++23)

<forward_list>
std::forward_list container
(C++11)

<list> std::list container
<map> std::map and std::multimap associative containers
<mdspan>
std::mdspan view
(C++23)

<queue> std::queue and std::priority_queue container adaptors


<set> std::set and std::multiset associative containers
<span>
std::span view
(C++20)

<stack> std::stack container adaptor


<unordered_map> std::unordered_map and std::unordered_multimap unordered
(C++11) associative containers

<unordered_set> std::unordered_set and std::unordered_multiset unordered
(C++11) associative containers

<vector> std::vector container
Iterators library
<iterator> Range iterators
Ranges library
<generator>
std::generator class template
(C++23)

<ranges>
Range access, primitives, requirements, utilities and adaptors
(C++20)

Algorithms library
<algorithm> Algorithms that operate on ranges
<execution> Predefined execution policies for parallel versions of the
(C++17) algorithms

Numerics library
<bit>
Bit manipulation functions
(C++20)

<cfenv>
Floating-point environment access functions
(C++11)

<cmath> Common mathematics functions


<complex> Complex number type
<numbers>
Math constants
(C++20)

<numeric> Numeric operations on values in ranges


<random>
Random number generators and distributions
(C++11)

<ratio>
Compile-time rational arithmetic
(C++11)

<valarray> Class for representing and manipulating arrays of values


Localization library
<clocale> C localization utilities
<codecvt>
Unicode conversion facilities
(C++11)(deprecated in C++17)

<locale> Localization utilities


Input/output library
<cstdio> C-style input-output functions
std::basic_fstream, std::basic_ifstream, std::basic_ofstream class
<fstream>
templates and several typedefs
<iomanip> Helper functions to control the format of input and output
std::ios_base class, std::basic_ios class template and several
<ios>
typedefs
<iosfwd> Forward declarations of all classes in the input/output library
<iostream> Several standard stream objects
<istream> std::basic_istream class template and several typedefs
std::basic_ostream, std::basic_iostream class templates and several
<ostream>
typedefs
<print>
Formatted output library including std::print
(C++23)

<spanstream> std::basic_spanstream, std::basic_ispanstream, std::basic_ospanstream 
(C++23) class templates and typedefs
std::basic_stringstream, std::basic_istringstream, std::basic_ostringstre
<sstream>
am class templates and several typedefs
<streambuf> std::basic_streambuf class template
<strstream>
std::strstream, std::istrstream, std::ostrstream
(deprecated in C++98)

<syncstream>
std::basic_osyncstream, std::basic_syncbuf, and typedefs
(C++20)

Filesystem library
<filesystem>
std::path class and supporting functions
(C++17)

Regular Expressions library


<regex> Classes, algorithms and iterators to support regular expression
(C++11) processing

Atomic Operations library


<atomic>
Atomic operations library
(C++11)

Thread support library


<barrier>
Barriers
(C++20)

<condition_variable>
Thread waiting conditions
(C++11)

<future>
Primitives for asynchronous computations
(C++11)

<latch>
Latches
(C++20)

<mutex>
Mutual exclusion primitives
(C++11)

<semaphore>
Semaphores
(C++20)

<shared_mutex>
Shared mutual exclusion primitives
(C++14)

<stop_token>
Stop tokens for std::jthread
(C++20)

<thread>
std::thread class and supporting functions
(C++11)

C compatibility headers
For some of the C standard library headers of the form xxx.h, the C++ standard library both
includes an identically-named header and another header of the form cxxx (all
meaningful cxxx headers are listed above). The intended use of headers of form xxx.h is for
interoperability only. It is possible that C++ source files need to include one of these headers in
order to be valid ISO C. Source files that are not intended to also be valid ISO C should not use
any of the C headers.
With the exception of complex.h , each xxx.h header included in the C++ standard library places in
the global namespace each name that the corresponding cxxx header would have placed in
the std namespace.
These headers are allowed to also declare the same names in the std namespace, and the
corresponding cxxx headers are allowed to also declare the same names in the global namespace:
including <cstdlib> definitely provides std::malloc and may also provide ::malloc.
Including <stdlib.h> definitely provides ::malloc and may also provide std::malloc. This
applies even to functions and function overloads that are not part of C standard library.
Notes: xxx.h headers are deprecated in C++98 and undeprecated in C++23. These headers are
discouraged for pure C++ code, but not subject to future removal.

<assert.h> Behaves same as <cassert>


<ctype.h> Behaves as if each name from <cctype> is placed in global namespace
<errno.h> Behaves same as <cerrno>
<fenv.h>
Behaves as if each name from <cfenv> is placed in global namespace
(C++11)

<float.h> Behaves same as <cfloat>


<inttypes.h> Behaves as if each name from <cinttypes> is placed in global namespace
(C++11)

<limits.h> Behaves same as <climits>


<locale.h> Behaves as if each name from <clocale> is placed in global namespace
Behaves as if each name from <cmath> is placed in global namespace,
<math.h>
except for names of mathematical special functions
<setjmp.h> Behaves as if each name from <csetjmp> is placed in global namespace
<signal.h> Behaves as if each name from <csignal> is placed in global namespace
<stdarg.h> Behaves as if each name from <cstdarg> is placed in global namespace
Behaves as if each name from <cstddef> is placed in global namespace,
<stddef.h>
except for names of std::byte and related functions
<stdint.h>
Behaves as if each name from <cstdint> is placed in global namespace
(C++11)

<stdio.h> Behaves as if each name from <cstdio> is placed in global namespace


<stdlib.h> Behaves as if each name from <cstdlib> is placed in global namespace
<string.h> Behaves as if each name from <cstring> is placed in global namespace
<time.h> Behaves as if each name from <ctime> is placed in global namespace
<uchar.h>
Behaves as if each name from <cuchar> is placed in global namespace
(C++11)

<wchar.h> Behaves as if each name from <cwchar> is placed in global namespace


<wctype.h> Behaves as if each name from <cwctype> is placed in global namespace
Special C compatibility headers
The header <stdatomic.h> declares names which are also provided in the C standard library, and
defines the _Atomic macro which is a keyword in C. Unlike other xxx.h headers,
corresponding <cstdatomic> is not provided.

<stdatomic.h> Defines _Atomic and provides corresponding components in the C


(C++23) standard library
Empty C headers
The headers <complex.h>, <ccomplex>, <tgmath.h>, and <ctgmath> do not contain any content from
the C standard library and instead merely include other headers from the C++ standard library.

<ccomplex> Simply includes the


(C++11)(deprecated in C++17)(removed in C++20) header <complex>

<complex.h> Simply includes the


(C++11) header <complex>
Simply includes the
headers <complex> and <cmath>: the
<ctgmath>
overloads equivalent to the contents
(C++11)(deprecated in C++17)(removed in C++20)
of the C header tgmath.h are already
provided by those headers
<tgmath.h> Simply includes the
(C++11) headers <complex> and <cmath>
Meaningless C headers
The headers <ciso646>, <cstdalign>, and <cstdbool> are meaningless in C++ because the macros
they provide in C are language keywords in C++.

<ciso646> Empty header. The macros that


appear in iso646.h in
(removed in C++20)
C are keywords in C++
<cstdalign> Defines one compatibility macro
(C++11)(deprecated in C++17)(removed in C++20) constant

<cstdbool> Defines one compatibility macro


(C++11)(deprecated in C++17)(removed in C++20) constant

<iso646.h> Has no effect


<stdalign.h> Defines one compatibility macro
(C++11) constant

<stdbool.h> Defines one compatibility macro


(C++11) constant

You might also like