简体   繁体   English

Windows 上的 C++20 编译器

[英]Compiler to C++20 on Windows

I need a compiler that supports c++20, like GCC 10.1 (used on linux), but to use it in my Windows 10.我需要一个支持 c++20 的编译器,例如 GCC 10.1(在 linux 上使用),但要在我的 Windows 10 中使用它。

I saw posts that recommend Mingw-w64, but does it supports c++20?我看到推荐Mingw-w64的帖子,但是它支持c++20吗?

In the meantime GCC 10 has been released and MinGW builds are available.与此同时,GCC 10 已经发布,MinGW 版本可用。

You can download a standalone build of MinGW-w64 with GCC 10 for Windows 32-bit and 64-bit from http://winlibs.com/您可以从http://wins.com/lib下载用于 Windows 32 位和 64 位的带有 GCC 10 的独立版 MinGW-w64

You can install Clang and MSVC/Visual Studio on Windows directly.您可以直接在 Windows 上安装 Clang 和 MSVC/Visual Studio。 For gcc you need MinGw /Msys2.对于 gcc,您需要 MinGw /Msys2。 I use wsl.我使用wsl。 With wsl you can check out gcc trunk and build it yourself.使用 wsl,您可以查看 gcc 主干并自己构建它。

C++20 is not completely supported but you can use most of it like coroutines, concepts... C++20 不完全受支持,但您可以使用其中的大部分内容,如协程、概念......

Other compilers usually lack behind those.其他编译器通常缺乏这些。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM