Remove some duplication.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66347 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Mikhail Glushenkov 2009-03-07 20:18:46 +00:00
parent 667d4b8de6
commit 0acf6b00f3

View File

@ -261,16 +261,19 @@ namespace llvmc {
return *this;
}
inline bool operator==(const ThisType& I) const
{ return EdgeIter == I.EdgeIter; }
inline bool operator!=(const ThisType& I) const
{ return EdgeIter != I.EdgeIter; }
inline bool operator==(const ThisType& I) const {
assert(OwningGraph == I.OwningGraph);
return EdgeIter == I.EdgeIter;
}
inline bool operator!=(const ThisType& I) const {
return !this->operator==(I);
}
inline pointer operator*() const {
return &OwningGraph->getNode((*EdgeIter)->ToolName());
}
inline pointer operator->() const {
return &OwningGraph->getNode((*EdgeIter)->ToolName());
return this->operator*();
}
ThisType& operator++() { ++EdgeIter; return *this; } // Preincrement