【C++20】
C++20，是继C++17之后的C++编程语言的ISO/IEC标准修订版的名称。2020年2月，该标准在布拉格的会议上由WG21进行了技术定稿。同年9月4日草案获得批准后，C++20同年12月正式发布。相比 C++17，C++20引入了新的语言特性，如概念、模块、操作符“”、协程、指定初始化、新标准属性等。C++20库标准还加入了范围、特性测试宏和位操作等。
== Features ==
与C++14 或 C++17相比，C++20增加了很多重大语法特性，其中四大为：
# Concept
# Ranges库
# 协程
# Modules
C++20新增的特性具体包括：
=== Language ===
* Concept使用简洁语法
* modules
* 指代初始化器 (基于C99特性和普通的g++扩展)
* =, this作为lambda捕获
* template parameter lists on lambdas
* 三路比较使用"宇宙飞船运算符", operator
* initialization of an additional variable within a range-based for statement
* lambdas in unevaluated contexts
* default constructible and assignable stateless lambdas
* allow pack expansions in lambda init-capture
* class types in non-type template parameters, also allowing string literals as template parameters
* removing the need for typename in certain circumstances
* new standard attributes ,  and
* conditional explicit, allowing the explicit modifier to be contingent on a boolean expression
* expanded constexpr: virtual functions, union, try and catch, dynamic_cast and typeid, std::pointer_traits
* immediate functions using the new consteval keyword
* signed integers are now defined to be represented using two's complement (signed integer overflow remains undefined behavior)
* a revised memory model
* various improvements to structured bindings (interaction with lambda captures, static and thread_local storage duration)
* coroutines
* using on scoped enums
* constinit keyword
=== Library ===
* ranges (The One Ranges Proposal)
* std::make_shared and std::allocate_shared for arrays
* atomic smart pointers (such as std::atomic> and std::atomic>)
* std::to_address to convert a pointer to a raw pointer
* calendar and time-zone additions to
* std::span, providing a view to a contiguous array (analogous to std::string_view but span can mutate the referenced sequence)
* std::erase and std::erase_if, simplifying element erasure for most standard containers
*  header
* std::bit_cast for type casting of object representations, with less verbosity than memcpy() and more ability to exploit compiler internals
* feature test macros
* various constexpr library bits
* smart pointer creation with default initialization
* contains-method for associative containers
* bit operations, such as leading/trailing zero/one count, and log2 operations
* std::bind_front
=== New and changed keywords ===
Many new keywords added (and the new "spaceship operator", operator ), such as concept, constinit, consteval, co_await, co_return, co_yield, requires (plus changed meaning for export), and char8_t (for UTF-8 support). And explicit can take an expression since C++20. Most of the uses of the volatile keyword have been deprecated.
In addition to keywords, there are identifiers with special meaning, including new import and module.
New attributes in C++20:
, ,  and
=== Removed and deprecated ===
Removed features:
* The C-derived headers , , ,  and  were removed, as they serve no purpose in C++. (The corresponding  headers remain, for compatibility with C.)
* The use of throw() as an exception specification was removed.
* Some previously deprecated library features were removed, including std::uncaught_exception,  std::raw_storage_iterator, std::is_literal_type, std::is_literal_type_v, std::result_of and std::result_of_t.
Deprecated features:
* Use of comma operator in subscript expressions has been deprecated
* (most of) volatile has been deprecated
== 作为Technical Specification发布 ==
* Parallelism TS v2 (包括task blocks)
* Reflection TS v1
* Networking TS v1
== 推迟到以后版本 ==
* Contracts
* Reflection
* Metaclass
* Executors
* Networking 扩展
* Properties
* Extended futures
== 编译器支持 ==
完全支持
* Visual Studio 2019支持C++20全部特性，从版本16.10.0通过/std:c++latest 选项。 从版本16.11.0开始通过/std:c++20选项。该选项的设定：Project properties→Configuration properties→C/C++→Language→C++ Language Standard.
Microsoft Visual Studio 2019也支持在Linux (以及Android 和 iOS)开发调试C++程序，这需要"Visual C++ for Linux Development extension"。
部分支持
* Clang从版本10开始使用-std=c++20或从版本9开始使用-std=c++2a编译选项.
* GCC从2017年开始部分实验性支持C++20 在版本8通过选项-std=c++2a. 在版本10使用-std=c++20选项。也可通过-std=gnu++20.