llvm.org GIT mirror llvm / 3b96359
Starting an identifier with an _ is not legal C/C++ code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13620 91177308-0d34-0410-b5e6-96231b3b80d8 Chris Lattner 16 years ago
1 changed file(s) with 7 addition(s) and 7 deletion(s). Raw diff Collapse all Expand all
8989 // BasicBlock succ_iterator definition
9090 //===--------------------------------------------------------------------===//
9191
92 template // Successor Iterator
93 class SuccIterator : public bidirectional_iterator<_BB, ptrdiff_t> {
94 const _Term Term;
92 template // Successor Iterator
93 class SuccIterator : public bidirectional_iterator {
94 const Term_ Term;
9595 unsigned idx;
96 typedef bidirectional_iterator<_BB, ptrdiff_t> super;
96 typedef bidirectional_iterator<BB_, ptrdiff_t> super;
9797 public:
98 typedef SuccIterator<_Term, _BB> _Self;
98 typedef SuccIterator<Term_, BB_> _Self;
9999 typedef typename super::pointer pointer;
100100 // TODO: This can be random access iterator, need operator+ and stuff tho
101101
102 inline SuccIterator(_Term T) : Term(T), idx(0) { // begin iterator
102 inline SuccIterator(Term_ T) : Term(T), idx(0) { // begin iterator
103103 assert(T && "getTerminator returned null!");
104104 }
105 inline SuccIterator(_Term T, bool) // end iterator
105 inline SuccIterator(Term_ T, bool) // end iterator
106106 : Term(T), idx(Term->getNumSuccessors()) {
107107 assert(T && "getTerminator returned null!");
108108 }