diff options
author | Douglas Gregor <dgregor@apple.com> | 2011-07-21 16:35:41 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2011-07-21 16:35:41 +0000 |
commit | 67029567f7d39d9356fbc505fffc2c1e21bf06ce (patch) | |
tree | 0f11d3c66438e0bbca77f90915eff71bdf067790 | |
parent | 8c24d1a29442ff362292ea1690452652bb49d1c6 (diff) |
Add the remaining RandomAccessIterator operations to
PreprocessingRecord::iterator. Where's concept_map when I need it?
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135679 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | include/clang/Lex/PreprocessingRecord.h | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/include/clang/Lex/PreprocessingRecord.h b/include/clang/Lex/PreprocessingRecord.h index 22a51665b4..22ac57152f 100644 --- a/include/clang/Lex/PreprocessingRecord.h +++ b/include/clang/Lex/PreprocessingRecord.h @@ -376,14 +376,26 @@ namespace clang { return X.Position == Y.Position; } + friend bool operator!=(const iterator &X, const iterator &Y) { + return X.Position != Y.Position; + } + friend bool operator<(const iterator &X, const iterator &Y) { return X.Position < Y.Position; } - friend bool operator!=(const iterator &X, const iterator &Y) { - return X.Position != Y.Position; + friend bool operator>(const iterator &X, const iterator &Y) { + return X.Position > Y.Position; + } + + friend bool operator<=(const iterator &X, const iterator &Y) { + return X.Position < Y.Position; } + friend bool operator>=(const iterator &X, const iterator &Y) { + return X.Position > Y.Position; + } + friend iterator& operator+=(iterator &X, difference_type D) { X.Position += D; return X; |