[libcxx-commits] [libcxx] 0b722a8 - [libc++] Translate the modules-support Lit feature to the DSL

Louis Dionne via libcxx-commits libcxx-commits at lists.llvm.org
Mon May 4 09:14:30 PDT 2020


Author: Louis Dionne
Date: 2020-05-04T12:14:19-04:00
New Revision: 0b722a8dba573f10dda1436d618988f7a36080c0

URL: https://github.com/llvm/llvm-project/commit/0b722a8dba573f10dda1436d618988f7a36080c0
DIFF: https://github.com/llvm/llvm-project/commit/0b722a8dba573f10dda1436d618988f7a36080c0.diff

LOG: [libc++] Translate the modules-support Lit feature to the DSL

Added: 
    

Modified: 
    libcxx/utils/libcxx/test/config.py
    libcxx/utils/libcxx/test/features.py

Removed: 
    


################################################################################
diff  --git a/libcxx/utils/libcxx/test/config.py b/libcxx/utils/libcxx/test/config.py
index dad44966dfb0..db640ab9ab8c 100644
--- a/libcxx/utils/libcxx/test/config.py
+++ b/libcxx/utils/libcxx/test/config.py
@@ -869,7 +869,6 @@ def configure_modules(self):
                 '-fmodules is enabled but not supported by the compiler')
         if not supports_modules:
             return
-        self.config.available_features.add('modules-support')
         module_cache = os.path.join(self.config.test_exec_root,
                                    'modules.cache')
         module_cache = os.path.realpath(module_cache)

diff  --git a/libcxx/utils/libcxx/test/features.py b/libcxx/utils/libcxx/test/features.py
index 7bdb9216787a..5332d1e9e0ce 100644
--- a/libcxx/utils/libcxx/test/features.py
+++ b/libcxx/utils/libcxx/test/features.py
@@ -31,6 +31,7 @@
                                                                  sys.platform.lower().strip() == 'darwin'), # TODO: this doesn't handle cross-compiling to Apple platforms.
   Feature(name='objective-c++',                 when=lambda cfg: hasCompileFlag(cfg, '-xobjective-c++ -fobjc-arc')),
   Feature(name='diagnose-if-support',           when=lambda cfg: hasCompileFlag(cfg, '-Wuser-defined-warnings'), compileFlag='-Wuser-defined-warnings'),
+  Feature(name='modules-support',               when=lambda cfg: hasCompileFlag(cfg, '-fmodules')),
 
   Feature(name='apple-clang',                                                                                                      when=_isAppleClang),
   Feature(name=lambda cfg: 'apple-clang-{__clang_major__}'.format(**compilerMacros(cfg)),                                          when=_isAppleClang),


        


More information about the libcxx-commits mailing list