[clang-tools-extra] r210070 - Don't assume an implicit error_code -> bool operator.
Rafael Espindola
rafael.espindola at gmail.com
Mon Jun 2 21:40:56 PDT 2014
Author: rafael
Date: Mon Jun 2 23:40:55 2014
New Revision: 210070
URL: http://llvm.org/viewvc/llvm-project?rev=210070&view=rev
Log:
Don't assume an implicit error_code -> bool operator.
Modified:
clang-tools-extra/trunk/unittests/clang-tidy/ClangTidyOptionsTest.cpp
Modified: clang-tools-extra/trunk/unittests/clang-tidy/ClangTidyOptionsTest.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/unittests/clang-tidy/ClangTidyOptionsTest.cpp?rev=210070&r1=210069&r2=210070&view=diff
==============================================================================
--- clang-tools-extra/trunk/unittests/clang-tidy/ClangTidyOptionsTest.cpp (original)
+++ clang-tools-extra/trunk/unittests/clang-tidy/ClangTidyOptionsTest.cpp Mon Jun 2 23:40:55 2014
@@ -19,14 +19,14 @@ TEST(ParseLineFilter, InvalidFilter) {
EXPECT_FALSE(parseLineFilter("asdf", Options));
EXPECT_TRUE(Options.LineFilter.empty());
- EXPECT_TRUE(parseLineFilter("[{}]", Options));
- EXPECT_TRUE(parseLineFilter("[{\"name\":\"\"}]", Options));
+ EXPECT_TRUE(!!parseLineFilter("[{}]", Options));
+ EXPECT_TRUE(!!parseLineFilter("[{\"name\":\"\"}]", Options));
EXPECT_TRUE(
- parseLineFilter("[{\"name\":\"test\",\"lines\":[[1]]}]", Options));
+ !!parseLineFilter("[{\"name\":\"test\",\"lines\":[[1]]}]", Options));
EXPECT_TRUE(
- parseLineFilter("[{\"name\":\"test\",\"lines\":[[1,2,3]]}]", Options));
+ !!parseLineFilter("[{\"name\":\"test\",\"lines\":[[1,2,3]]}]", Options));
EXPECT_TRUE(
- parseLineFilter("[{\"name\":\"test\",\"lines\":[[1,-1]]}]", Options));
+ !!parseLineFilter("[{\"name\":\"test\",\"lines\":[[1,-1]]}]", Options));
}
TEST(ParseLineFilter, ValidFilter) {
More information about the cfe-commits
mailing list