diff options
| author | Marshall Clow <mclow.lists@gmail.com> | 2014-03-11 22:05:31 +0000 |
|---|---|---|
| committer | Marshall Clow <mclow.lists@gmail.com> | 2014-03-11 22:05:31 +0000 |
| commit | 668a1d8c44e6659b0b0d4d48daa3c0f79b77f6d5 (patch) | |
| tree | 2a10b0a5b4c191504d75141beca28ee6f7910ee3 /include | |
| parent | be3d117702db7dc87b1ad12a365e472bb8846f89 (diff) | |
| download | external_libcxx-668a1d8c44e6659b0b0d4d48daa3c0f79b77f6d5.tar.gz external_libcxx-668a1d8c44e6659b0b0d4d48daa3c0f79b77f6d5.tar.bz2 external_libcxx-668a1d8c44e6659b0b0d4d48daa3c0f79b77f6d5.zip | |
Fix ABI break I made in r203587; thanks to Richard Smith for the catch.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@203610 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
| -rw-r--r-- | include/iterator | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/include/iterator b/include/iterator index 4c6b0a607..263ff3f51 100644 --- a/include/iterator +++ b/include/iterator @@ -538,16 +538,18 @@ class _LIBCPP_TYPE_VIS_ONLY reverse_iterator { protected: _Iter current; +private: + mutable _Iter __t; // no longer used as of LWG #2360, not removed due to ABI break public: typedef _Iter iterator_type; typedef typename iterator_traits<_Iter>::difference_type difference_type; typedef typename iterator_traits<_Iter>::reference reference; typedef typename iterator_traits<_Iter>::pointer pointer; - _LIBCPP_INLINE_VISIBILITY reverse_iterator() : current() {} - _LIBCPP_INLINE_VISIBILITY explicit reverse_iterator(_Iter __x) : current(__x) {} + _LIBCPP_INLINE_VISIBILITY reverse_iterator() : current(), __t() {} + _LIBCPP_INLINE_VISIBILITY explicit reverse_iterator(_Iter __x) : current(__x), __t() {} template <class _Up> _LIBCPP_INLINE_VISIBILITY reverse_iterator(const reverse_iterator<_Up>& __u) - : current(__u.base()) {} + : current(__u.base()), __t() {} _LIBCPP_INLINE_VISIBILITY _Iter base() const {return current;} _LIBCPP_INLINE_VISIBILITY reference operator*() const {_Iter __tmp = current; return *--__tmp;} _LIBCPP_INLINE_VISIBILITY pointer operator->() const {return _VSTD::addressof(operator*());} |
