Closed wg21bot closed 4 years ago
The NB commenter's proposed change was incorrectly copied from #287 but should have been to change V
to Base
(see https://github.com/ericniebler/stl2/issues/573 for the equivalent change).
LWG Friday AM in Belfast. We think that the change should have been described as:
- constexpr iterator(Parent& parent, iterator_t<V> outer)
+ constexpr iterator(Parent& parent, iterator_t<Base> outer)
General agreement on direction; TS to write issue.
LWG Saturday PM in Belfast. Resolved by the adoption of P1983R0 in Prague.
Accepted with modification. See paper P1983R0.
join_view::iterator's constructor is incorrect. In join_view<V>::iterator<Const>, we see the constructor:
V above is the non-const-qualified view template parameter. We will then try to initialize the outer_ data member with outer, which has type iterator_t<Base>, where Base is const V when Const is true, and V otherwise. This is broken; there is no required conversion if the types are different. Fixing this will probably require changes also to join_view's begin() and end() members.
Proposed change: In [range.join.view], change the joinview<V>::inner member to be mutable. This is safe because this exposition-only member is only used when the join_view is single-pass and only modified by operations that invalidate other iterators.
See https://cplusplus.github.io/LWG/issue3278