[libcxx-commits] [PATCH] D120684: [libc++] Define _LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER whenever we enable warnings in the test suite
Louis Dionne via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Mon Feb 28 13:55:17 PST 2022
ldionne created this revision.
Herald added a subscriber: arichardson.
ldionne requested review of this revision.
Herald added a project: libc++.
Herald added a subscriber: libcxx-commits.
Herald added a reviewer: libc++.
This should make CI consistent on all the compilers we support.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D120684
Files:
libcxx/utils/libcxx/test/features.py
libcxx/utils/libcxx/test/params.py
Index: libcxx/utils/libcxx/test/params.py
===================================================================
--- libcxx/utils/libcxx/test/params.py
+++ libcxx/utils/libcxx/test/params.py
@@ -117,9 +117,10 @@
Parameter(name='enable_warnings', choices=[True, False], type=bool, default=True,
help="Whether to enable warnings when compiling the test suite.",
- actions=lambda warnings: [] if not warnings else [
- AddOptionalWarningFlag(w) for w in _warningFlags
- ]),
+ actions=lambda warnings: [] if not warnings else
+ [AddOptionalWarningFlag(w) for w in _warningFlags] +
+ [AddCompileFlag('-D_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER')]
+ ),
Parameter(name='debug_level', choices=['', '0', '1'], type=str, default='',
help="The debugging level to enable in the test suite.",
Index: libcxx/utils/libcxx/test/features.py
===================================================================
--- libcxx/utils/libcxx/test/features.py
+++ libcxx/utils/libcxx/test/features.py
@@ -103,8 +103,7 @@
Feature(name=lambda cfg: 'apple-clang-{__clang_major__}.{__clang_minor__}'.format(**compilerMacros(cfg)), when=_isAppleClang),
Feature(name=lambda cfg: 'apple-clang-{__clang_major__}.{__clang_minor__}.{__clang_patchlevel__}'.format(**compilerMacros(cfg)), when=_isAppleClang),
- Feature(name='clang', when=_isClang,
- actions=[AddCompileFlag('-D_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER')]),
+ Feature(name='clang', when=_isClang),
Feature(name=lambda cfg: 'clang-{__clang_major__}'.format(**compilerMacros(cfg)), when=_isClang),
Feature(name=lambda cfg: 'clang-{__clang_major__}.{__clang_minor__}'.format(**compilerMacros(cfg)), when=_isClang),
Feature(name=lambda cfg: 'clang-{__clang_major__}.{__clang_minor__}.{__clang_patchlevel__}'.format(**compilerMacros(cfg)), when=_isClang),
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D120684.411889.patch
Type: text/x-patch
Size: 2230 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20220228/367aaa40/attachment.bin>
More information about the libcxx-commits
mailing list