From 30e304e2a646ccd5f34d5697cad0be9dcccfaa2d Mon Sep 17 00:00:00 2001 From: Richard Smith Date: Wed, 14 Dec 2016 00:03:17 +0000 Subject: Remove custom handling of array copies in lambda by-value array capture and copy constructors of classes with array members, instead using ArrayInitLoopExpr to represent the initialization loop. This exposed a bug in the static analyzer where it was unable to differentiate between zero-initialized and unknown array values, which has also been fixed here. llvm-svn: 289618 --- clang/unittests/Tooling/RecursiveASTVisitorTest.cpp | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'clang/unittests/Tooling/RecursiveASTVisitorTest.cpp') diff --git a/clang/unittests/Tooling/RecursiveASTVisitorTest.cpp b/clang/unittests/Tooling/RecursiveASTVisitorTest.cpp index a2aedb64859..7e08f9619c1 100644 --- a/clang/unittests/Tooling/RecursiveASTVisitorTest.cpp +++ b/clang/unittests/Tooling/RecursiveASTVisitorTest.cpp @@ -133,25 +133,6 @@ TEST(RecursiveASTVisitor, AttributesAreVisited) { "};\n")); } -// Check to ensure that VarDecls are visited. -class VarDeclVisitor : public ExpectedLocationVisitor { -public: - bool VisitVarDecl(VarDecl *VD) { - Match(VD->getNameAsString(), VD->getLocStart()); - return true; - } -}; - -TEST(RecursiveASTVisitor, ArrayInitializersAreVisited) { - VarDeclVisitor Visitor; - Visitor.ExpectMatch("__i0", 1, 8); - EXPECT_TRUE( - Visitor.runOver("struct MyClass {\n" - " int c[1];\n" - " static MyClass Create() { return MyClass(); }\n" - "};\n")); -} - // Check to ensure that implicit default argument expressions are visited. class IntegerLiteralVisitor : public ExpectedLocationVisitor { -- cgit v1.2.3