[clang-tidy] Mention language version in test explicitly.
authorVolodymyr Sapsai <vsapsai@apple.com>
Thu, 14 Feb 2019 22:37:30 +0000 (22:37 +0000)
committerVolodymyr Sapsai <vsapsai@apple.com>
Thu, 14 Feb 2019 22:37:30 +0000 (22:37 +0000)
"modernize-use-using" check is applicable only to C++11 and later. Spell it out
to avoid relying on default language version.

rdar://problem/47932196

llvm-svn: 354069

clang-tools-extra/test/clang-tidy/clang-tidy-mac-libcxx.cpp

index 153a5d6..d124a34 100644 (file)
@@ -8,7 +8,7 @@
 // RUN: cp -r %S/Inputs/mock-libcxx %t/
 //
 // Pretend clang is installed beside the mock library that we provided.
-// RUN: echo '[{"directory":"%t","command":"%t/mock-libcxx/bin/clang++ -stdlib=libc++ -target x86_64-apple-darwin -c test.cpp","file":"test.cpp"}]' | sed -e 's/\\/\//g' > %t/compile_commands.json
+// RUN: echo '[{"directory":"%t","command":"%t/mock-libcxx/bin/clang++ -stdlib=libc++ -std=c++11 -target x86_64-apple-darwin -c test.cpp","file":"test.cpp"}]' | sed -e 's/\\/\//g' > %t/compile_commands.json
 // RUN: cp "%s" "%t/test.cpp"
 // RUN: clang-tidy -header-filter='.*' -system-headers -checks='-*,modernize-use-using'  "%t/test.cpp" | FileCheck %s
 // CHECK: mock_vector:{{[0-9]+}}:{{[0-9]+}}: warning: use 'using' instead of 'typedef'