SuccIterator on bbs without terminator insts
authorTobias Grosser <grosser@fim.uni-passau.de>
Mon, 4 Jul 2011 23:09:02 +0000 (23:09 +0000)
committerTobias Grosser <grosser@fim.uni-passau.de>
Mon, 4 Jul 2011 23:09:02 +0000 (23:09 +0000)
commit598179ee2f5a31d4b2d3932963a3714ab235ec2e
tree2cebce09d62bba08b26572e699f1808e71b9ff20
parentfc87cdc1f4df357167a7cef91af92b5012934124
SuccIterator on bbs without terminator insts

Remove the assert that triggers if SuccIterator is constructed for a basic block
without a terminator instruction. Instead of triggering an assert a succ_end()
iterator is returned. This models a basic block with zero successors and allows
us to use F->viewCFG() on incompletely constructed functions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134398 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Support/CFG.h