Add missing C++ STL iterator declarations and correct their const/non-const behaviour. (GH-4528)
The current implementation of iterators had the following bugs: - it was possible to assign `const_iterator` to `iterator` - it was not possible to assign `iterator` to `const_iterator` - operator* did not always return `value_type` e.g. for `const_iterator` this often returned `T&` instead of `const value_type&` - increment operators always returned `iterators`. This caused e.g. `const_iterator + 1` to result in a `iterator` instead of a `const_iterator` - comparision operators could not be used to compare `iterators` and `const_iterators` (`const_iterator == iterator`)
Showing
Please register or sign in to comment