在 C++20 中使用模块
Using modules in c++20
我正在尝试编译这个程序。 Live here
import std.core;
int main()
{
std::cout<<"ravioli";
}
我在读 Modules in C++ 20。源只有关于 运行 它在 Microsoft C++ 编译器上的信息。有没有其他编译器实现了模块?如果是,我需要什么额外的标志来编译这个程序。
据 Reddit, the stl
modules like stl.core
or stl.io
are just a Microsoft thing and is intended as a starting point for a C++23 proposal. They're just a repackaging of the existing Standard Library with no organizational changes other than dividing them into five or so groups. You can found more about this in the Overview of modules in C++ or in the OpenSTD paper 中的一位 STL 开发人员称。
我正在尝试编译这个程序。 Live here
import std.core;
int main()
{
std::cout<<"ravioli";
}
我在读 Modules in C++ 20。源只有关于 运行 它在 Microsoft C++ 编译器上的信息。有没有其他编译器实现了模块?如果是,我需要什么额外的标志来编译这个程序。
据 Reddit, the stl
modules like stl.core
or stl.io
are just a Microsoft thing and is intended as a starting point for a C++23 proposal. They're just a repackaging of the existing Standard Library with no organizational changes other than dividing them into five or so groups. You can found more about this in the Overview of modules in C++ or in the OpenSTD paper 中的一位 STL 开发人员称。