[libcxx-commits] [libcxx] [libc++][C++03] Fix tests that are failing due to private includes (PR #139900)

Louis Dionne via libcxx-commits libcxx-commits at lists.llvm.org
Wed May 14 07:26:53 PDT 2025


https://github.com/ldionne requested changes to this pull request.

My immediate reaction to this is that I don't think the added complexity is worth it. I'd rather either:

1. disable those tests in C++03 entirely, or
2. include public headers instead, but that requires changing the "policy" that we basically include everything in the subdirectory `__foo` from a public header `<foo>`.

The third option is this: We technically have two implementations now, one for C++ >= 11 and one for C++03. So in a way, we should really have two copies of `libcxx/test/libcxx`, one for each implementation. And we'd keep `libcxx/test/libcxx/cxx03` stable pretty much forever, basically. From a quick survey, we seem to have 909 tests in `libcxx/test/libcxx`, at least 500 of which are not supported in C++03 mode. So it might actually be reasonable to duplicate the rest of those tests. At the end of the day, that's the difference between having test coverage for C++03 implementation details or not having any such coverage, long term. So I think it's worth investigating.

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


More information about the libcxx-commits mailing list