-
- Downloads
[libc++][C++03] Use `__cxx03/` headers in C++03 mode (#109002)
This patch implements the forwarding to frozen C++03 headers as discussed in https://discourse.llvm.org/t/rfc-freezing-c-03-headers-in-libc. In the RFC, we initially proposed selecting the right headers from the Clang driver, however consensus seemed to steer towards handling this in the library itself. This patch implements that direction. At a high level, the changes basically amount to making each public header look like this: ``` // inside <vector> #ifdef _LIBCPP_CXX03_LANG # include <__cxx03/vector> #else // normal <vector> content #endif ``` In most cases, public headers are simple umbrella headers so there isn't much code in the #else branch. In other cases, the #else branch contains the actual implementation of the header.
Showing
- .github/workflows/libcxx-build-and-test.yaml 1 addition, 0 deletions.github/workflows/libcxx-build-and-test.yaml
- libcxx/cmake/caches/Generic-cxx03-frozen.cmake 2 additions, 0 deletionslibcxx/cmake/caches/Generic-cxx03-frozen.cmake
- libcxx/include/CMakeLists.txt 1020 additions, 0 deletionslibcxx/include/CMakeLists.txt
- libcxx/include/__cxx03/CMakeLists.txt 0 additions, 1092 deletionslibcxx/include/__cxx03/CMakeLists.txt
- libcxx/include/__cxx03/__config 1 addition, 1 deletionlibcxx/include/__cxx03/__config
- libcxx/include/__cxx03/__configuration/abi.h 1 addition, 1 deletionlibcxx/include/__cxx03/__configuration/abi.h
- libcxx/include/__cxx03/__configuration/compiler.h 1 addition, 1 deletionlibcxx/include/__cxx03/__configuration/compiler.h
- libcxx/include/__cxx03/__configuration/config_site_shim.h 80 additions, 0 deletionslibcxx/include/__cxx03/__configuration/config_site_shim.h
- libcxx/include/__cxx03/__configuration/language.h 1 addition, 1 deletionlibcxx/include/__cxx03/__configuration/language.h
- libcxx/include/__cxx03/__configuration/platform.h 1 addition, 1 deletionlibcxx/include/__cxx03/__configuration/platform.h
- libcxx/include/__cxx03/__locale_dir/locale_base_api/bsd_locale_fallbacks.h 1 addition, 1 deletion...cxx03/__locale_dir/locale_base_api/bsd_locale_fallbacks.h
- libcxx/include/__cxx03/__thread/support/pthread.h 2 additions, 2 deletionslibcxx/include/__cxx03/__thread/support/pthread.h
- libcxx/include/__cxx03/climits 1 addition, 1 deletionlibcxx/include/__cxx03/climits
- libcxx/include/__cxx03/locale 1 addition, 1 deletionlibcxx/include/__cxx03/locale
- libcxx/include/__cxx03/module.modulemap 989 additions, 989 deletionslibcxx/include/__cxx03/module.modulemap
- libcxx/include/__cxx03/version 3 additions, 3 deletionslibcxx/include/__cxx03/version
- libcxx/include/algorithm 4 additions, 3 deletionslibcxx/include/algorithm
- libcxx/include/any 4 additions, 3 deletionslibcxx/include/any
- libcxx/include/array 4 additions, 3 deletionslibcxx/include/array
- libcxx/include/atomic 4 additions, 3 deletionslibcxx/include/atomic
Loading