<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Tue, Mar 11, 2014 at 3:05 PM, Marshall Clow <span dir="ltr"><<a href="mailto:mclow.lists@gmail.com" target="_blank">mclow.lists@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: marshall<br>
Date: Tue Mar 11 17:05:31 2014<br>
New Revision: 203610<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=203610&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=203610&view=rev</a><br>
Log:<br>
Fix ABI break I made in r203587; thanks to Richard Smith for the catch.<br>
<br>
Modified:<br>
    libcxx/trunk/include/iterator<br>
<br>
Modified: libcxx/trunk/include/iterator<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/iterator?rev=203610&r1=203609&r2=203610&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/iterator?rev=203610&r1=203609&r2=203610&view=diff</a><br>

==============================================================================<br>
--- libcxx/trunk/include/iterator (original)<br>
+++ libcxx/trunk/include/iterator Tue Mar 11 17:05:31 2014<br>
@@ -538,16 +538,18 @@ class _LIBCPP_TYPE_VIS_ONLY reverse_iter<br>
 {<br>
 protected:<br>
     _Iter current;<br>
+private:<br>
+    mutable _Iter __t;  // no longer used as of LWG #2360, not removed due to ABI break<br></blockquote><div><br></div><div>For this to be ABI-compatible with the old iterator, you'll need to keep these two variables the other way around.</div>
<div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
 public:<br>
     typedef _Iter                                            iterator_type;<br>
     typedef typename iterator_traits<_Iter>::difference_type difference_type;<br>
     typedef typename iterator_traits<_Iter>::reference       reference;<br>
     typedef typename iterator_traits<_Iter>::pointer         pointer;<br>
<br>
-    _LIBCPP_INLINE_VISIBILITY reverse_iterator() : current() {}<br>
-    _LIBCPP_INLINE_VISIBILITY explicit reverse_iterator(_Iter __x) : current(__x) {}<br>
+    _LIBCPP_INLINE_VISIBILITY reverse_iterator() : current(), __t() {}<br>
+    _LIBCPP_INLINE_VISIBILITY explicit reverse_iterator(_Iter __x) : current(__x), __t() {}<br>
     template <class _Up> _LIBCPP_INLINE_VISIBILITY reverse_iterator(const reverse_iterator<_Up>& __u)<br>
-        : current(__u.base()) {}<br>
+        : current(__u.base()), __t() {}<br>
     _LIBCPP_INLINE_VISIBILITY _Iter base() const {return current;}<br>
     _LIBCPP_INLINE_VISIBILITY reference operator*() const {_Iter __tmp = current; return *--__tmp;}<br>
     _LIBCPP_INLINE_VISIBILITY pointer  operator->() const {return _VSTD::addressof(operator*());}<br>
<br>
<br>
_______________________________________________<br>
cfe-commits mailing list<br>
<a href="mailto:cfe-commits@cs.uiuc.edu">cfe-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits</a><br>
</blockquote></div><br></div></div>