Fix const_reverse_iterator constructor (pass const ptr)
This commit is contained in:
parent
300851ec16
commit
33aed5bf89
1 changed files with 1 additions and 1 deletions
|
@ -132,7 +132,7 @@ public:
|
|||
typedef const T* pointer;
|
||||
typedef const T& reference;
|
||||
typedef std::bidirectional_iterator_tag iterator_category;
|
||||
const_reverse_iterator(T* ptr_) : ptr(ptr_) {}
|
||||
const_reverse_iterator(const T* ptr_) : ptr(ptr_) {}
|
||||
const_reverse_iterator(reverse_iterator x) : ptr(&(*x)) {}
|
||||
const T& operator*() const { return *ptr; }
|
||||
const T* operator->() const { return ptr; }
|
||||
|
|
Loading…
Reference in a new issue