Re: [PATCH 3/3, 11 backport] libstdc++: invalid default init in _CachedPosition [PR101231]

2022-02-11 Thread Jonathan Wakely via Gcc-patches
On Thu, 10 Feb 2022 at 16:58, Patrick Palka via Libstdc++ wrote: > > The primary template for _CachedPosition is a dummy implementation for > non-forward ranges, the iterators for which generally can't be cached. > Because this implementation doesn't actually cache anything, _M_has_value > is defi

[PATCH 3/3, 11 backport] libstdc++: invalid default init in _CachedPosition [PR101231]

2022-02-10 Thread Patrick Palka via Gcc-patches
The primary template for _CachedPosition is a dummy implementation for non-forward ranges, the iterators for which generally can't be cached. Because this implementation doesn't actually cache anything, _M_has_value is defined to be false and so calls to _M_get (which are always guarded by _M_has_v