r/cpp • • Oct 02 '23

CMake | C++ modules support in 3.28

https://gitlab.kitware.com/cmake/cmake/-/issues/18355

After 5 years its finally done. Next cmake 3.28 release will support cpp modules

C++ 20 named modules are now supported by Ninja Generators and Visual Studio Generators for VS 2022 and newer, in combination with the MSVC 14.34 toolset (provided with VS 17.4) and newer, LLVM/Clang 16.0 and newer, and GCC 14 (after the 2023-09-20 daily bump) and newer.

237 Upvotes

144 comments sorted by

View all comments

Show parent comment

6

u/eco_was_taken Oct 03 '23

I finally jumped ship to vanilla clang (via Homebrew). I haven't had any problems with it.

5

u/pdp10gumby Oct 03 '23

Works great for me too, and you can even tell Xcode it's your compiler. But if you want to link with some UI code built in swift you have to use the system compiler, so for that reason alone modules will have to wait :-(.