C++ fixed compile error C2678 with msvc when using std::find_if on vectors (#4262)

In Debug mode it is checked that iterator begin is less than end
therefore the operator< in class VectorIterator is needed
This commit is contained in:
schoetbi 2017-04-13 01:37:22 +02:00 committed by Wouter van Oortmerssen
parent e6fa7b1133
commit 1fc12e0e5b
1 changed files with 4 additions and 0 deletions

View File

@ -296,6 +296,10 @@ public:
return data_ == other.data_;
}
bool operator<(const VectorIterator &other) const {
return data_ < other.data_;
}
bool operator!=(const VectorIterator &other) const {
return data_ != other.data_;
}