Re: [committed 2/3] libstdc++: Add remaining C++20 changes to iterator adaptors

2020-03-28 Thread Jonathan Wakely via Gcc-patches
On 28/03/20 00:16 +, Jonathan Wakely wrote: On 27/03/20 23:29 +, Jonathan Wakely wrote: @@ -403,6 +428,49 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION operator>=(const reverse_iterator<_IteratorL>& __x, const reverse_iterator<_IteratorR>& __y) { return !(__x < __y); } +#else

Re: [committed 2/3] libstdc++: Add remaining C++20 changes to iterator adaptors

2020-03-27 Thread Jonathan Wakely via Gcc-patches
On 27/03/20 23:29 +, Jonathan Wakely wrote: @@ -403,6 +428,49 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION operator>=(const reverse_iterator<_IteratorL>& __x, const reverse_iterator<_IteratorR>& __y) { return !(__x < __y); } +#else // C++20 + template +constexpr auto +

[committed 2/3] libstdc++: Add remaining C++20 changes to iterator adaptors

2020-03-27 Thread Jonathan Wakely via Gcc-patches
This adds the missing parts of P0896R4 to reverse_iterator and move_iterator, so that they meet the C++20 requirements. This should be the last piece of P0896R4, meaning ranges support is now complete. The PR 94354 bug with reverse_iterator's comparisons is fixed for C++20 only, but that change