clang-tools-extra/test/clang-tidy/line-filter.cpp: Tweak line-filter.
authorNAKAMURA Takumi <geek4civic@gmail.com>
Sat, 24 May 2014 08:42:12 +0000 (08:42 +0000)
committerNAKAMURA Takumi <geek4civic@gmail.com>
Sat, 24 May 2014 08:42:12 +0000 (08:42 +0000)
On win32, %s is expanded to X:\path\to\test\line-filter.cpp. It was incompatible to yaml.
Although "%/s" could be available in Lit, ClangTidyDiagnosticConsumer::passesLineFilter() is unaware of comparision between '/' and '\\'.

llvm-svn: 209569

clang-tools-extra/test/clang-tidy/line-filter.cpp

index 5b20e77..a2fdbb4 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: clang-tidy -checks='-*,google-explicit-constructor' -line-filter='[{"name":"%s","lines":[[18,18],[22,22]]},{"name":"header1.h","lines":[[1,2]]},{"name":"header2.h"},{"name":"header3.h"}]' -header-filter='header[12]\.h$' %s -- -I %S/Inputs/line-filter 2>&1 | FileCheck %s
+// RUN: clang-tidy -checks='-*,google-explicit-constructor' -line-filter='[{"name":"line-filter.cpp","lines":[[18,18],[22,22]]},{"name":"header1.h","lines":[[1,2]]},{"name":"header2.h"},{"name":"header3.h"}]' -header-filter='header[12]\.h$' %s -- -I %S/Inputs/line-filter 2>&1 | FileCheck %s
 
 #include "header1.h"
 // CHECK-NOT: header1.h:{{.*}} warning