
This removes the entire modules testing infrastructure. The current infrastructure uses CMake to generate the std and std.compat module. This requires quite a bit of plumbing and uses CMake. Since CMake introduced module support in CMake 3.26, modules have a higher CMake requirement than the rest of the LLVM project. (The LLVM project requires 3.20.) The main motivation for this approach was how libc++ generated its modules. Every header had its own module partition. This was changed to improve performance and now only two modules remain. The code to build these can be manually crafted. A followup patch will reenable testing modules, using a different approach.
The "module partitions" for the std module
The files in this directory contain the exported named declarations per header. These files are used for the following purposes:
- During testing exported named declarations are tested against the named declarations in the associated header. This excludes reserved names; they are not exported.
- Generate the module std.
These use cases require including the required headers for these "partitions" at different locations. This means the user of these "partitions" are responsible for including the proper header and validating whether the header can be loaded in the current libc++ configuration. For example "include " fails when locales are not available. The "partitions" use the libc++ feature macros to export the declarations available in the current configuration. This configuration is available if the user includes the `__config' header.
We use .inc
files that we include from the top-level module instead of
using real C++ module partitions. This is a lot faster than module partitions,
see this for details.