[libcxx-commits] [libcxx] [libc++] First attempt to regroup a few modules in the modulemap (PR #98214)

Vassil Vassilev via libcxx-commits libcxx-commits at lists.llvm.org
Tue Sep 3 13:54:19 PDT 2024


vgvassilev wrote:

> There's just no good way to deal with `#include_next` in modules other than every such header has to be its own module. Which means all of the cstdlib headers whether they're in the base library, clang, or libc++. And once you've done that, you have to modularize all the way down or you get a plethora of issues from including non-modular headers from modular headers.

There is a good way to deal with this: `[no_undeclared_includes]`, however, you classified it as a hack which is subjective.

> Modules aren't a good solution to a size deficiency in PCH, it sounds like that just needs to be fixed.

Yes, they are. We cannot fix the size deficiency in the PCH because it is a space constraint and will penalize people with smaller PCH sizes. Modules give us layering pretty much the same reason for why Apple uses it (along with other things). I will keep asking for a case of a cycle which is not fixed by `[no_undeclared_includes]`.


https://github.com/llvm/llvm-project/pull/98214


More information about the libcxx-commits mailing list