From: Chris Lattner Date: Thu, 18 Oct 2007 16:26:24 +0000 (+0000) Subject: this doesn't need dynamic_cast. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=b7daa84a3500105a9e5245b463155fcb15ed6730;p=oota-llvm.git this doesn't need dynamic_cast. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43133 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/VMCore/Constants.cpp b/lib/VMCore/Constants.cpp index 9c1377dbd7b..262595fc8f3 100644 --- a/lib/VMCore/Constants.cpp +++ b/lib/VMCore/Constants.cpp @@ -580,7 +580,7 @@ Constant *ConstantExpr::getXor(Constant *C1, Constant *C2) { } unsigned ConstantExpr::getPredicate() const { assert(getOpcode() == Instruction::FCmp || getOpcode() == Instruction::ICmp); - return dynamic_cast(this)->predicate; + return ((const CompareConstantExpr*)this)->predicate; } Constant *ConstantExpr::getShl(Constant *C1, Constant *C2) { return get(Instruction::Shl, C1, C2);