[libcxx-commits] [libcxx] [libc++][test] Enhance `ADDITIONAL_COMPILE_FLAGS` to work with MSVC (PR #74974)
Stephan T. Lavavej via libcxx-commits
libcxx-commits at lists.llvm.org
Sun Dec 10 05:00:21 PST 2023
================
@@ -13,7 +13,12 @@
import subprocess
import sys
-_isClang = lambda cfg: "__clang__" in compilerMacros(cfg) and "__apple_build_version__" not in compilerMacros(cfg)
+_isAnyClangOrGCC = lambda cfg: "__clang__" in compilerMacros(
+ cfg
+) or "__GNUC__" in compilerMacros(cfg)
----------------
StephanTLavavej wrote:
Great idea, I've pushed a commit to do that. Note that I took a slightly different approach, introducing `_isAnyGCC` so that `_isAnyClangOrGCC`'s evaluation will be more efficient.
https://github.com/llvm/llvm-project/pull/74974
More information about the libcxx-commits
mailing list