1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 11:42:57 +01:00

fix const correctness, BB is const, so its predecessors are too

llvm-svn: 43780
This commit is contained in:
Chris Lattner 2007-11-06 22:07:40 +00:00
parent 2a909d32b6
commit 8e982efdc5

View File

@ -155,7 +155,7 @@ bool CodeGenPrepare::CanMergeBlocks(const BasicBlock *BB,
if (!DestBBPN) return true; // no conflict.
// Collect the preds of BB.
SmallPtrSet<BasicBlock*, 16> BBPreds;
SmallPtrSet<const BasicBlock*, 16> BBPreds;
if (const PHINode *BBPN = dyn_cast<PHINode>(BB->begin())) {
// It is faster to get preds from a PHI than with pred_iterator.
for (unsigned i = 0, e = BBPN->getNumIncomingValues(); i != e; ++i)