Coroutines & Modules Added For C++20

Written by Michael Larabel in Standards on 23 February 2019 at 05:32 PM EST. 38 Comments
The ISO C++ committee has wrapped up its winter meeting in Hawaii that also served as the last meeting for approving new features for the upcoming C++20 revision to the C++ programming language.

At this week's meeting, the last of the C++20 features were considered while at the next meeting in the summer will be taking care of some loose ends and then taking C++20 to the international comment ballot.

Two previously talked about features that have been under consideration for C++20 were officially approved: modules and coroutines. C++ modules are an alternative to C++ header files that make it simpler to use software libraries and provides for better compile-time scalability and avoid various shortcomings of the compiler's pre-processor behavior. The coroutine concept is similar to the functionality in other programming languages for non-preemptive multitasking and the approved C++ coroutines state is similar to the experimental support already in LLVM Clang (in fact, they have now enabled it with the -std=c++2a switch).

At this week's meeting they also adopted new vectorization policies for the parallel STL algorithms, polymorphic_allocator was added, std::span changes, and other smaller work.

These latest changes come on top of other previously approved additions including C++ concepts, designated initializers, ranges, a revised memory model, a three-way comparison operator, feature test macros, and much more.

More details on the latest decisions around C++20 can be found via this trip report by Herb Sutter.

For those wondering about the current C++20 state in the GCC compiler can see this status matrix as well as the Clang status.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via

Popular News This Week