libstdc++: make common_iterator<I, S> require copyable<I> (LWG 3385)
* include/bits/stl_iterator.h (common_iterator): Add copyable<I> requirement (LWG 3385). * testsuite/24_iterators/headers/iterator/synopsis_c++20.cc: Adjust expected declaration.
This commit is contained in:
parent
7433536b3d
commit
1b425f3ac5
@ -1,5 +1,10 @@
|
||||
2020-02-19 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
* include/bits/stl_iterator.h (common_iterator): Add copyable<I>
|
||||
requirement (LWG 3385).
|
||||
* testsuite/24_iterators/headers/iterator/synopsis_c++20.cc: Adjust
|
||||
expected declaration.
|
||||
|
||||
* include/std/ranges (take_while_view, drop_view, drop_while_view)
|
||||
(elements_view:_Iterator): Initialize data members (LWG 3364).
|
||||
|
||||
|
@ -1426,7 +1426,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
|
||||
/// An iterator/sentinel adaptor for representing a non-common range.
|
||||
template<input_or_output_iterator _It, sentinel_for<_It> _Sent>
|
||||
requires (!same_as<_It, _Sent>)
|
||||
requires (!same_as<_It, _Sent>) && copyable<_It>
|
||||
class common_iterator
|
||||
{
|
||||
template<typename _Tp, typename _Up>
|
||||
|
@ -56,7 +56,7 @@ namespace std
|
||||
template<semiregular S> class move_sentinel;
|
||||
|
||||
template<input_or_output_iterator I, sentinel_for<I> S>
|
||||
requires (!same_as<I, S>)
|
||||
requires (!same_as<I, S>) && copyable<I>
|
||||
class common_iterator;
|
||||
|
||||
template<class I, class S>
|
||||
|
Loading…
Reference in New Issue
Block a user