GCC 10 Adds Late Support For -std=c++20 To Target C++20
With C++20 now effectively complete, GCC developers have made a rather late change for GCC 10 that is also long overdue and that is introducing the -std=c++20 switch for targeting C++20.
The GNU Compiler Collection has been working on C++20 support for a while and has much of it ironed out. But up until now -std=c++2a had to be used for specifying this support that was pretty much a given C++2A would be called C++20. With this C++ revision going to publication in the next few months, it will surely be known as C++20 in making it out before the end of the calendar year.
Thus GCC 10 now also honors -std=c++20. Red Hat's Jason Merrill noted in the weekend commit, "It's probably past time for this, but definitely now that we're done with the final committee meeting of C++20. This patch only adds the option and adjusts the testsuite to recognize it; more extensive changes can wait for the published standard."
The current state of GCC's C++ support can be found via this documentation. Going back to GCC 8 has been portions of new C++20 features while for GCC 10 the concepts support is ironed out, the consistent comparison operator is now supported, partial support for consteval immediate functions, Unicode improvements, and other improvements. Yet to be completed in GCC is the C++20 modules support, using enum, atomic compare-and-exchange with padding bits, and other minor items.
Meanwhile the LLVM Clang C++20 status is here with portions of concepts still to be completed, modules, and other items but a lot is in place with Clang 9 and the forthcoming Clang 10.
The GNU Compiler Collection has been working on C++20 support for a while and has much of it ironed out. But up until now -std=c++2a had to be used for specifying this support that was pretty much a given C++2A would be called C++20. With this C++ revision going to publication in the next few months, it will surely be known as C++20 in making it out before the end of the calendar year.
Thus GCC 10 now also honors -std=c++20. Red Hat's Jason Merrill noted in the weekend commit, "It's probably past time for this, but definitely now that we're done with the final committee meeting of C++20. This patch only adds the option and adjusts the testsuite to recognize it; more extensive changes can wait for the published standard."
The current state of GCC's C++ support can be found via this documentation. Going back to GCC 8 has been portions of new C++20 features while for GCC 10 the concepts support is ironed out, the consistent comparison operator is now supported, partial support for consteval immediate functions, Unicode improvements, and other improvements. Yet to be completed in GCC is the C++20 modules support, using enum, atomic compare-and-exchange with padding bits, and other minor items.
Meanwhile the LLVM Clang C++20 status is here with portions of concepts still to be completed, modules, and other items but a lot is in place with Clang 9 and the forthcoming Clang 10.
11 Comments