stl_algobase.h
50 KB
-
PR libstdc++/86658 fix __niter_wrap to not copy invalid iterators · e874029d
An output iterator passed as the unused first argument to __niter_wrap might have already been invalidated, so don't copy it. PR libstdc++/86658 * include/bits/stl_algobase.h (__niter_wrap<_Iterator>): Pass unused parameter by reference, to avoid copying invalid iterators. * testsuite/25_algorithms/copy/86658.cc: New test. From-SVN: r262952
Jonathan Wakely committed