GCC Developers Discuss Possible -std=c++current & -std=c++future Options
![GNU](/assets/categories/gnu.webp)
The idea is to have GCC support "-std=c++current" that would be a moving target to the current C++ specification supported by the compiler while "-std=c++future" would be for targeting the current work-in-progress/draft C++ specification in current working form. There would also be similar gnu++current / gnu++future options for the GNU C++ extended variants.
While the idea is nice, in practice some concerns have already been raised over this being a constant moving target and may lead to user confusion. In particular, with developers/users often running a compiler that can be a year or several years old, the "current" and "future" targets will mean different C++ versions and not necessarily what is actually the current/future target at the time of use. Especially on enterprise Linux distributions where users out-of-the-box can be running a several year old compiler, interpreting the meaning of current/future will not necessarily be accurate with what the user is expecting.
For now the proposed GCC options are being discussed in this gcc-patches mailing list thread for those interested in the prospects of -std=c++current and -std=c++future.
16 Comments