History of C++
- 1979: C with Classes first implemented
- New features: classes, member functions, derived classes, separate compilation, public and private access control, friends, type checking of function arguments, default arguments, inline functions, overloaded assignment operator, constructors, destructors, f() same as f(void), call-function and return-function (synchronization features, not in C++)
- Libraries: the concurrent task library (not in C++)
- 1982: C with Classes reference manual published
- 1984: C84 implemented, reference manual published
- 1985: Cfront 1.0
- New features: virtual functions, function and operator overloading, references, new and delete operators, the keyword const, scope resolution operator
- Library additions: complex, string, iostream
- 1985: The C++ Programming Language, 1st edition
- 1986: The "whatis?" paper documenting the remaining design goals, including multiple inheritance, exception handling, and templates.
- 1987: C++ support in GCC 1.15.3
- 1989: Cfront 2.0
- New features: multiple inheritance, pointers to members, protected access, type-safe linkage, abstract classes, static and const member functions, class-specific new and delete
- Library additions: I/O manipulators
- 1990: The Annotated C++ Reference Manual
This book described the language as designed, including some features that were not yet implemented. It served as the de-facto standard until the ISO.
- 1991: Cfront 3.0
- 1991: The C++ Programming Language, 2nd edition
- 1990 ANSI C++ Committee founded
- 1991 ISO C++ Committee founded
- 1992 STL implemented in C++
- New features: RTTI (dynamic_cast, typeid), covariant return types, cast operators, mutable, bool, declarations in conditions, template instantiations, member templates, export
- Library additions: locales, bitset, valarray, auto_ptr, templatized string, iostream, and complex.
- Based on STL: containers, algorithms, iterators, function objects
- 1998 The C++ Programming Language, 3rd edition
- 1999 Boost founded by the committee members to produce new high-quality candidate libraries for the standard.
This was a minor revision, intended to be little more than a technical corrigendum
- New features: value initialization
This TR discussed the costs of various C++ abstractions, provided implementation guidance, discussed use of C++ in embedded systems and introduced
<hardware> interface to C's ISO/IEC TR 18037:2008
This TR is a C++ library extension, which adds the following to the C++ standard library:
- From Boost: Reference wrapper, Smart pointers, Member function, Result Of, Bind, Function, Type Traits, Random, Mathematical Special Functions, Tuple, Array, Unordered Containers (including Hash), and Regular Expressions.
- From C99: mathematical functions from math.h that were new in C99, blank character class, Floating-point environment, hexfloat I/O Manipulator, fixed-size integral types, the long long type, va_copy, the snprintf() and vfscanf() families of functions, and the C99 conversion specifies for printf() and scanf() families of functions.
All of TR1 except for the special functions was included in C++11, with minor changes.
This international standard is a C++ standard library extension, which adds the special functions that were part of TR1, but were not included in C++11: elliptic integrals, exponential integral, Laguerre polynomials, Legendre polynomials, Hermite polynomials, Bessel functions, Neumann functions, beta function, and Riemann zeta function. This standard was merged into C++17.
A large number of changes were introduced to both standardize existing practices and improve the abstractions available to the C++ programmers
- New language features: auto and decltype, defaulted and deleted functions, final and override, trailing return type, rvalue references, move constructors/move assignment, scoped enums, constexpr and literal types, list initialization, delegating and inherited constructors, brace-or-equal initializers, nullptr, long long, char16_t and char32_t, type aliases, variadic templates, generalized unions, generalized PODs, Unicode string literals, user-defined literals, attributes, lambda expressions, noexcept, alignof and alignas, multithreaded memory model, thread-local storage, GC interface, range for (based on a Boost library), static assertions (based on a Boost library)
- New library features: atomic operations library, emplace() and other use of rvalue references throughout all parts of the existing library, std::initializer_list, stateful and scoped allocators, forward_list, chrono library, ratio library, new algorithms, Unicode conversion facets
- From TR1: all of TR1 except Special Functions.
- From Boost: The thread library, exception_ptr, error_code and error_condition, iterator improvements (std::begin, std::end, std::next, std::prev)
- From C: C-style Unicode conversion functions
This TR implements the decimal floating-point types from IEEE 754-2008 Standard for Floating-Point Arithmetic: std::decimal::decimal32, std::decimal::decimal64, and std::decimal::decimal128.
- 2012 The Standard C++ Foundation founded
- 2013 The C++ Programming Language, 4th edition
C++14(ISO Store) (ANSI Store) (2014 final draft)
Minor revision of the C++ standard
- New language features: variable templates, polymorphic lambdas, lambda captures expressions, new/delete elision, relaxed restrictions on constexpr functions, binary literals, digit separators, return type deduction for functions, aggregate initialization for classes with brace-or-equal initializers.
- New library features: std::make_unique, std::shared_timed_mutex and std::shared_lock, std::integer_sequence, std::exchange, std::quoted, and many small improvements to existing library facilities, such as two-range overloads for some algorithms, type alias versions of type traits, user-defined string, duration, and complex number literals, etc.
This TS is an experimental C++ library extension that specifies a filesystem library based on boost.filesystem V3 (with some modifications and extensions). This TS was merged into C++17.
This TS standardizes parallel and vector-parallel API for all standard library algorithms, as well as adds new algorithms such as
exclusive_scan. This TS was merged into C++17.
This TS extends the C++ core language with synchronized and atomic blocks, as well as transaction-safe functions, which implement transactional memory semantics.
This TS adds several new components to the C++ standard library: optional, any, string_view, sample, search, apply, polymorphic allocators, and variable templates for type traits. This TS was merged into C++17.
This TS extends the C++ core language with concepts (named type requirements) and constraints (limits on the types allowed in template, function, and variable declarations), which aids metaprogramming and simplifies template instantiation diagnostics, see concepts. This TS was merged into C++20, with some omissions.
This TS extends the C++ library to include several extensions to std::future, latches and barriers, and atomic smart pointers.
- Language changes: fold-expressions, class template argument deduction, auto non-type template parameters, compile-time if constexpr, inline variables, structured bindings, initializers for if and switch, u8-char, simplified nested namespaces, using-declaration can declare multiple names, made noexcept part of type system, new order of evaluation rules, allocation functions with explicit alignment, guaranteed copy elision, __has_include, lambda capture of *this, constexpr lambda, attribute namespaces don't have to repeat, new attributes
[[maybe_unused]]. Removed trigraphs, the register keyword, bool increment
- Library changes: std::variant, std::launder, uninitialized memory tools (std::destroy_at/std::destroy/std::destroy_n, std::uninitialized_move, std::uninitialized_value_construct, etc), map/set extract and map/set merge, byte, std::make_from_tuple, std::to_chars/from_chars, relative path support in Filesystem (proximate, relative, weakly_canonical), directory entry caching in Filesystem, contiguous iterators, non-member size/empty/data, map/unordered_map try_emplace and insert_or_assign, uncaught_exceptions, variadic lock_guard, as_const, conjunction/disjunction/negation, type trait variables xxx_v, transparent owner_less, rounding functions for duration and time_point, array support for std::shared_ptr, not_fn, weak_from_this, is_always_lock_free, is_swappable, clamp, 3D hypot, cache line interface, is_invocable, is_aggregate, has_unique_object_representations. Deprecated
std::result_of, all of
<codecvt>Removed auto_ptr, the deprecated function objects, std::random_shuffle, std::unexpected, the obsolete iostreams aliases.
- From TS's: the filesystem library, the library fundamentals v1 (including optional, any, string_view, polymorphic allocators, searchers, apply), parallelism v1 (including execution policies, reduce, inclusive_scan, exclusive_scan), but removing
exception_list. From special math IS: special mathematical functions, from library fundamentals v2: std::gcd, std::lcm
- From C11: std::aligned_alloc, std::timespec_get
This TS extends the C++ library to include ranges, a new, more powerful, abstraction to replace iterator pairs, along with range views, sentinel ranges, projections for on-the-fly transformations, new iterator adaptors and algorithms. This extension finally makes it possible to sort a vector with sort(v);
This TS extends the C++ library to include TCP/IP networking based on boost.asio.
This TS extends the C++ library to include two new execution policies (unseq and vec), additional parallel algorithms such as reduction_plus or for_loop_strided, task blocks for forking and joining parallel tasks, SIMD types and operations on those types.
- 2020 C++20 (2019-03-15 draft)
The next major revision of the C++ standard
- Language changes: 3-way comparison operator <=> and operator==() = default, designated initializers, init-statements and initializers in range-for, char8_t,
[[unlikely]], pack-expansions in lambda captures, removed the requirement to use
typenameto disambiguate types in many contexts,
consteval, further relaxed constexpr, signed integers are 2's complement, aggregate initialization using parentheses, array new can deduce array size
- From TS's: Coroutines, Modules, Concepts, abbreviated function templates,
- Library changes: Calendar and Time Zone library, std::span, std::endian, array support for make_shared, std::remove_cvref, std::to_address, floating point and shared_ptr atomics,
<version>, std::osyncstream, std::u8string and other char8_t uses, constexpr for <algorithm>, <utility>, <complex>, std::string(_view)::starts_with and ends_with, std::assume_aligned, std::bind_front, c8rtomb/mbrtoc8, make_obj_using_allocator etc, make_shared_default_init/make_unique_default_init, heterogeneous lookup in unordered_map etc, fully-specialized std::polymoprhic_allocator<>, std::execution::unseq, std::midpoint and std::lerp, std::ssize. std::is_bounded_array, lookup in unordered containers can use pre-calculated hash
- From TS's: Ranges, uniform container erasure (std::erase/std::erase_if)