aboutsummaryrefslogtreecommitdiff
path: root/clang
diff options
context:
space:
mode:
authorFangrui Song <i@maskray.me>2021-02-08 13:37:03 -0800
committerFangrui Song <i@maskray.me>2021-02-08 13:37:04 -0800
commit87dbdd2e3bb63b681f8cc3179ef5c2d5929bbf61 (patch)
treef7715781410fb4481455147f2762d59f3303b8d3 /clang
parentad60802a7187aa39b0374536be3fa176fe3d6256 (diff)
downloadllvm-87dbdd2e3bb63b681f8cc3179ef5c2d5929bbf61.zip
llvm-87dbdd2e3bb63b681f8cc3179ef5c2d5929bbf61.tar.gz
llvm-87dbdd2e3bb63b681f8cc3179ef5c2d5929bbf61.tar.bz2
[FileCheck] Default --allow-unused-prefixes to false
Link: https://lists.llvm.org/pipermail/llvm-dev/2020-October/146162.html "[RFC] FileCheck: (dis)allowing unused prefixes" If a downstream project using lit needs time for transition, add the following to `lit.local.cfg`: ``` from lit.llvm.subst import ToolSubst fc = ToolSubst('FileCheck', unresolved='fatal') config.substitutions.insert(0, (fc.regex, 'FileCheck --allow-unused-prefixes')) ``` Differential Revision: https://reviews.llvm.org/D95849
Diffstat (limited to 'clang')
-rw-r--r--clang/test/Driver/crash-report-null.test2
-rw-r--r--clang/test/OpenMP/lit.local.cfg7
-rw-r--r--clang/test/lit.cfg.py8
3 files changed, 2 insertions, 15 deletions
diff --git a/clang/test/Driver/crash-report-null.test b/clang/test/Driver/crash-report-null.test
index 05309bf6..c5e3b3b 100644
--- a/clang/test/Driver/crash-report-null.test
+++ b/clang/test/Driver/crash-report-null.test
@@ -1,7 +1,7 @@
// RUN: env FORCE_CLANG_DIAGNOSTICS_CRASH=1 not %clang -fsyntax-only -x c /dev/null -lstdc++ 2>&1 | FileCheck %s
// FIXME: Investigating. "fatal error: file 'nul' modified since it was first processed"
-// XFAIL: windows-gnu
+// UNSUPPORTED: system-windows
// CHECK: PLEASE submit a bug report to {{.*}} and include the crash backtrace, preprocessed source, and associated run script.
// CHECK: Preprocessed source(s) and associated run script(s) are located at:
diff --git a/clang/test/OpenMP/lit.local.cfg b/clang/test/OpenMP/lit.local.cfg
index ac72c2d..c114693 100644
--- a/clang/test/OpenMP/lit.local.cfg
+++ b/clang/test/OpenMP/lit.local.cfg
@@ -2,9 +2,4 @@
from lit.llvm.subst import ToolSubst
fc = ToolSubst('FileCheck', unresolved='fatal')
-# the parent introduced the opposite rule, so we replace it if we see it.
-if len(config.substitutions) > 0 and config.substitutions[0] == (fc.regex, 'FileCheck --allow-unused-prefixes=false'):
- config.substitutions[0] = (
- fc.regex, 'FileCheck --allow-unused-prefixes=true')
-else:
- config.substitutions.insert(0, (fc.regex, 'FileCheck --allow-unused-prefixes=true'))
+config.substitutions.insert(0, (fc.regex, 'FileCheck --allow-unused-prefixes'))
diff --git a/clang/test/lit.cfg.py b/clang/test/lit.cfg.py
index a47ebe7..863ab44 100644
--- a/clang/test/lit.cfg.py
+++ b/clang/test/lit.cfg.py
@@ -43,14 +43,6 @@ llvm_config.use_default_substitutions()
llvm_config.use_clang()
-# FIXME: remove this when we flip the default value for --allow-unused-prefixes
-# to false.
-fc = ToolSubst('FileCheck', unresolved='fatal')
-# Insert this first. Then, we'll first update the blank FileCheck command; then,
-# the default substitution of FileCheck will replace it to its full path.
-config.substitutions.insert(0, (fc.regex,
- 'FileCheck --allow-unused-prefixes=false'))
-
config.substitutions.append(
('%src_include_dir', config.clang_src_dir + '/include'))