From: Matt Beaumont-Gay Date: Tue, 1 Nov 2011 18:10:22 +0000 (+0000) Subject: Silence a warning in -Asserts builds X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2eb0ce3610a877f75e95c66d6c2bff315e127009;p=clang Silence a warning in -Asserts builds git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143471 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Sema/SemaDeclCXX.cpp b/lib/Sema/SemaDeclCXX.cpp index c43db52132..60a128165f 100644 --- a/lib/Sema/SemaDeclCXX.cpp +++ b/lib/Sema/SemaDeclCXX.cpp @@ -2143,10 +2143,8 @@ Sema::BuildDelegatingInitializer(TypeSourceInfo *TInfo, if (DelegationInit.isInvalid()) return true; - CXXConstructExpr *ConExpr = cast(DelegationInit.get()); - CXXConstructorDecl *Constructor - = ConExpr->getConstructor(); - assert(Constructor && "Delegating constructor with no target?"); + assert(cast(DelegationInit.get())->getConstructor() && + "Delegating constructor with no target?"); CheckImplicitConversions(DelegationInit.get(), Args.getStartLoc());