On 18/05/21 00:53 -0400, Patrick Palka via Libstdc++ wrote:
On Mon, 17 May 2021, Tim Song wrote:
On Mon, May 17, 2021 at 2:59 PM Patrick Palka wrote:
>
> + constexpr _CachedPosition&
> + operator=(_CachedPosition&& __other) noexcept
> + {
> + if (std::__addressof(__ot
On Mon, 17 May 2021, Tim Song wrote:
> On Mon, May 17, 2021 at 2:59 PM Patrick Palka wrote:
> >
> > + constexpr _CachedPosition&
> > + operator=(_CachedPosition&& __other) noexcept
> > + {
> > + if (std::__addressof(__other) != this)
>
> I don't think we need this check
On Mon, May 17, 2021 at 2:59 PM Patrick Palka wrote:
>
> + constexpr _CachedPosition&
> + operator=(_CachedPosition&& __other) noexcept
> + {
> + if (std::__addressof(__other) != this)
I don't think we need this check - self-move-assigning the underlying
view isn't requi
On Mon, 17 May 2021, Tim Song wrote:
> On Mon, May 17, 2021 at 11:46 AM Patrick Palka via Libstdc++
> wrote:
> > constexpr void
> > _M_set(const _Range&, const iterator_t<_Range>& __it)
> > {
> > __glibcxx_assert(!_M_has_value());
> > - _M_iter = __it;
>
On Mon, May 17, 2021 at 11:46 AM Patrick Palka via Libstdc++
wrote:
> constexpr void
> _M_set(const _Range&, const iterator_t<_Range>& __it)
> {
> __glibcxx_assert(!_M_has_value());
> - _M_iter = __it;
> + this->_M_payload._M_payload._M_value = __i
On 17/05/21 11:43 -0400, Patrick Palka via Libstdc++ wrote:
This fixes two issues with our iterator caching as described in detail
in the PR. Since r12-336 added the __non_propagating_cache class
template as part of P2328, this patch just rewrites the _CachedPosition
partial specialization in te