I'm unsure what the "best" C++ compilers (ease of installation, updateability usability, supported C++ standard, code perf.) are on current Windows systems, not counting MSVC. MSys, MinGW, Gygwin, etc. ...
It's on the Winget package manager (the official application package manager for Windows) as LLVM. It's probably on others too, but keep in mind it may be listed as LLVM rather than Clang for some reason.
Note you will also need the Windows SDK. I haven't looked to see if that's on a package manager, and I don't know if it includes the MS STL or you have to install that too.
I just normally install the lot via the Visual Studio installer (not VS Code). VS 2022 is actually really good.
That's a common pattern: UNIX distributions package the compiler as "clang" half the time, "llvm" the other half of the time.
For people interested in cross-platform development, the inconsistency in package composition and naming is one more unnecessary inconvenience to manage.
I installed it via Visual Studio Installer, because I already had it on my system. Other options might be available, but I haven't personally tried them.
22
u/Trider12 Mar 01 '23
Clang. It's even available as an option in Visual Studio.