https://llvm.org/bugs/show_bug.cgi?id=26088
Bug ID: 26088 Summary: Some AST matcher tests fail to compile on Visual Studio 2015. Product: clang Version: unspecified Hardware: PC OS: Windows NT Status: NEW Severity: normal Priority: P Component: libclang Assignee: unassignedclangb...@nondot.org Reporter: juj...@gmail.com CC: kli...@google.com, llvm-bugs@lists.llvm.org Classification: Unclassified Building trunk LLVM+Clang, in file tools\clang\unittests\ASTMatchers\ASTMatchersTest.cpp, the following three tests fail to compile: TEST(HasDeclaration, HasDeclarationOfTypeWithDecl) { EXPECT_TRUE(matches("typedef int X; X a;", varDecl(hasName("a"), hasType(typedefType(hasDeclaration(decl())))))); // FIXME: Add tests for other types with getDecl() (e.g. RecordType) } which results in http://pastebin.com/iqMexcy1, and TEST(TypeMatching, MatchesRecordType) { EXPECT_TRUE(matches("class C{}; C c;", recordType())); EXPECT_TRUE(matches("struct S{}; S s;", recordType(hasDeclaration(recordDecl(hasName("S")))))); EXPECT_TRUE(notMatches("int i;", recordType(hasDeclaration(recordDecl(hasName("S")))))); } which results in http://pastebin.com/7S83kTCT, and TEST(ElaboratedTypeNarrowing, namesType) { EXPECT_TRUE(matches( "namespace N {" " namespace M {" " class D {};" " }" "}" "N::M::D d;", elaboratedType(elaboratedType(namesType(recordType( hasDeclaration(namedDecl(hasName("D"))))))))); EXPECT_TRUE(notMatches( "namespace M {" " class D {};" "}" "M::D d;", elaboratedType(elaboratedType(namesType(typedefType()))))); } which results in http://pastebin.com/TnSHB6Ep. -- You are receiving this mail because: You are on the CC list for the bug.
_______________________________________________ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs