Implement operator= for SuccIterators

llvm-svn: 4055
This commit is contained in:
Chris Lattner 2002-10-07 16:53:22 +00:00
parent 5b17790ba5
commit 6fa8a99101
1 changed files with 5 additions and 0 deletions

View File

@ -100,6 +100,11 @@ public:
: Term(T), idx(Term->getNumSuccessors()) {
assert(T && "getTerminator returned null!");
}
inline const _Self &operator=(const _Self &I) {
assert(Term == I.Term &&"Cannot assign iterators to two different blocks!");
idx = I.idx;
}
inline bool operator==(const _Self& x) const { return idx == x.idx; }
inline bool operator!=(const _Self& x) const { return !operator==(x); }