2018-06-13 François Dumont <fdumont@gcc.gnu.org>
authorFrançois Dumont <fdumont@gcc.gnu.org>
Wed, 13 Jun 2018 20:27:26 +0000 (20:27 +0000)
committerFrançois Dumont <fdumont@gcc.gnu.org>
Wed, 13 Jun 2018 20:27:26 +0000 (20:27 +0000)
commiteb04ee1d0f23b14c251a850f2a26429d324b1f6f
tree30635dfd4a3cb91099144aed2e26f667c1567867
parent3b07c0e5e45a5594e9929adf898736af7b6839da
2018-06-13  François Dumont  <fdumont@gcc.gnu.org>

* include/debug/helper_functions.h
(__gnu_debug::_Safe_iterator<>): Add declaration.
(__can_advance(_Ite, _Size)): New.
(__can_advance(const _Safe_iterator<>&, _Size)): Overload declaration.
* include/debug/functions.h
(__gnu_debug::_Safe_iterator<>): Remove declaration.
* include/debug/stl_iterator.h
(__can_advance(const _Safe_iterator<>&)): New definition.
* include/debug/stl_iterator.h
(__can_advance(const std::reverse_iterator<>&, _Size)): New.
(__can_advance(const std::move_iterator<>&, _Size)): New.
* include/debug/macros.h (__glibcxx_check_can_increment): New.
* include/debug/debug.h (__glibcxx_requires_can_increment): New.
* include/bits/stl_algobase.h (fill_n): Use latter.
* testsuite/25_algorithms/fill_n/2.cc: New.
* testsuite/25_algorithms/fill_n/debug/1_neg.cc: New.
* testsuite/25_algorithms/fill_n/debug/2_neg.cc: New.
* testsuite/25_algorithms/fill_n/debug/3_neg.cc: New.
* testsuite/25_algorithms/fill_n/debug/4_neg.cc: New.

From-SVN: r261566
13 files changed:
libstdc++-v3/ChangeLog
libstdc++-v3/include/bits/stl_algobase.h
libstdc++-v3/include/debug/debug.h
libstdc++-v3/include/debug/functions.h
libstdc++-v3/include/debug/helper_functions.h
libstdc++-v3/include/debug/macros.h
libstdc++-v3/include/debug/safe_iterator.h
libstdc++-v3/include/debug/stl_iterator.h
libstdc++-v3/testsuite/25_algorithms/fill_n/2.cc [new file with mode: 0644]
libstdc++-v3/testsuite/25_algorithms/fill_n/debug/1_neg.cc [new file with mode: 0644]
libstdc++-v3/testsuite/25_algorithms/fill_n/debug/2_neg.cc [new file with mode: 0644]
libstdc++-v3/testsuite/25_algorithms/fill_n/debug/3_neg.cc [new file with mode: 0644]
libstdc++-v3/testsuite/25_algorithms/fill_n/debug/4_neg.cc [new file with mode: 0644]