From: Jakub Staszak Date: Sat, 9 Mar 2013 18:24:26 +0000 (+0000) Subject: Remove unneeded const_cast. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=64bf55af6f3cc6c6db985d3840547b5869e57222;p=oota-llvm.git Remove unneeded const_cast. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@176771 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/Analysis/LoopInfo.h b/include/llvm/Analysis/LoopInfo.h index b583b717bd3..783e347522d 100644 --- a/include/llvm/Analysis/LoopInfo.h +++ b/include/llvm/Analysis/LoopInfo.h @@ -147,10 +147,10 @@ public: /// block that is outside of the current loop. /// bool isLoopExiting(const BlockT *BB) const { - typedef GraphTraits BlockTraits; + typedef GraphTraits BlockTraits; for (typename BlockTraits::ChildIteratorType SI = - BlockTraits::child_begin(const_cast(BB)), - SE = BlockTraits::child_end(const_cast(BB)); SI != SE; ++SI) { + BlockTraits::child_begin(BB), + SE = BlockTraits::child_end(BB); SI != SE; ++SI) { if (!contains(*SI)) return true; } @@ -165,8 +165,8 @@ public: typedef GraphTraits > InvBlockTraits; for (typename InvBlockTraits::ChildIteratorType I = - InvBlockTraits::child_begin(const_cast(H)), - E = InvBlockTraits::child_end(const_cast(H)); I != E; ++I) + InvBlockTraits::child_begin(H), + E = InvBlockTraits::child_end(H); I != E; ++I) if (contains(*I)) ++NumBackEdges;