]> granicus.if.org Git - clang/commitdiff
Replace a dyn_cast with a cast when we know the exact type
authorDouglas Gregor <dgregor@apple.com>
Tue, 28 Oct 2008 15:29:51 +0000 (15:29 +0000)
committerDouglas Gregor <dgregor@apple.com>
Tue, 28 Oct 2008 15:29:51 +0000 (15:29 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@58330 91177308-0d34-0410-b5e6-96231b3b80d8

lib/AST/Expr.cpp

index f330444f1d40e82e7073c540d1e4fb493aa4cb79..b2cf6adfc16c29a86a1b970345e106be1dafe592 100644 (file)
@@ -398,7 +398,7 @@ Expr::isLvalueResult Expr::isLvalue(ASTContext &Ctx) const {
     //   A function call is an lvalue if and only if the result type
     //   is a reference.
     QualType CalleeType 
-      = dyn_cast<CallExpr>(this)->getCallee()->IgnoreParens()->getType();
+      = cast<CallExpr>(this)->getCallee()->IgnoreParens()->getType();
     if (const PointerType *FnTypePtr = CalleeType->getAsPointerType())
       if (const FunctionType *FnType
             = FnTypePtr->getPointeeType()->getAsFunctionType())