Vladimir,

The e = end() is no longer needed.

Cheers,

-- Jim


On Jun 8, 2006, at 12:46 PM, Vladimir Prus wrote:

+Instruction* BasicBlock::getFirstNonPHI()

+{

+    BasicBlock::iterator i = begin(), e = end();

+    // All valid basic blocks should have a terminator,

+    // which is not a PHINode. If we have invalid basic

+    // block we'll get assert when dereferencing past-the-end

+    // iterator.

+    while (isa<PHINode>(i)) ++i;

+    return &*i;

+}

+


Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

Reply via email to