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

Add iterator ranges for blocks in a Loop.

llvm-svn: 249873
This commit is contained in:
Owen Anderson 2015-10-09 18:40:15 +00:00
parent ac5187dedd
commit 57bd7dc824

View File

@ -140,6 +140,9 @@ public:
typedef typename std::vector<BlockT*>::const_iterator block_iterator;
block_iterator block_begin() const { return Blocks.begin(); }
block_iterator block_end() const { return Blocks.end(); }
inline iterator_range<block_iterator> blocks() const {
return iterator_range<block_iterator>(block_begin(), block_end());
}
/// getNumBlocks - Get the number of blocks in this loop in constant time.
unsigned getNumBlocks() const {