哪个 gcc 和 g++ 版本支持 c 和 c++ 的哪个标准?

2022-01-23 00:00:00 gcc c standards g++ c++

例如,哪个gcc版本支持c99?

For example, which gcc version support c99?

是否有任何表格或图表显示 gcc 和 g++ 的标准支持状态?

Is there any table or graph to show the standard supported status of gcc and g++?

gcc 和 g++ 是如何演变的?

How gcc and g++ evolved?

谢谢~

推荐答案

非常严格地说,GCC 从 4.3 开始肯定只支持 C89、C++98 和 C++03.

Very strictly speaking, GCC only supports C89, C++98 and C++03, all for sure since 4.3.

到目前为止,对 C99 的支持仍然不完整,但 GCC 长期以来一直支持一个非常大且可用的子集.

Support for C99 is still incomplete as of yet, but a very large and usable subset has been supported by GCC for a long time.

实验性的 C++11 支持从 4.3 开始,并且一直在改进;它在 4.6.x 中已经非常有用了,并且在 4.7 中添加了更多功能(虽然 4.7.0 有点不稳定).

Experiemental C++11 support started with 4.3 and has been improving ever since; it's already very usable in 4.6.x, and a lot more has been added in 4.7 (though 4.7.0 is a bit unstable).

还有一些 C11 支持,但 C11 的许多更改都需要一个适当的新 C 库,而这不是那么容易替换的.

There is also some C11 support, but many of the changes for C11 require a suitably new C library, which is not so easily replaceable.

相关文章