diff options
author | Patrick Palka <ppalka@redhat.com> | 2020-02-12 12:54:47 -0500 |
---|---|---|
committer | Patrick Palka <ppalka@redhat.com> | 2020-02-13 15:22:28 -0500 |
commit | 613c932f5e5c0cc2e4b88e21d9870fa7b1a6ce5d (patch) | |
tree | 9114e54b284f671bb7177b24fb4959679c6afc78 /gcc | |
parent | 90fc7b3ce0ee24c08b1edd40c528467939ef9d4f (diff) | |
download | gcc-613c932f5e5c0cc2e4b88e21d9870fa7b1a6ce5d.zip gcc-613c932f5e5c0cc2e4b88e21d9870fa7b1a6ce5d.tar.gz gcc-613c932f5e5c0cc2e4b88e21d9870fa7b1a6ce5d.tar.bz2 |
libstdc++: Implement ranges [specialized.algorithms]
This implements all the ranges members defined in [specialized.algorithms]:
ranges::uninitialized_default_construct
ranges::uninitialized_value_construct
ranges::uninitialized_copy
ranges::uninitialized_copy_n
ranges::uninitialized_move
ranges::uninitialized_move_n
ranges::uninitialized_fill
ranges::uninitialized_fill_n
ranges::construct_at
ranges::destroy_at
ranges::destroy
It also implements (hopefully correctly) the "obvious" optimizations for these
algos, namely that if the output range has a trivial value type and if the
appropriate operation won't throw then we can dispatch to the standard ranges
version of the algorithm which will then potentially enable further
optimizations.
libstdc++-v3/ChangeLog:
* include/Makefile.am: Add <bits/ranges_uninitialized.h>.
* include/Makefile.in: Regenerate.
* include/bits/ranges_uninitialized.h: New header.
* include/std/memory: Include it.
* testsuite/20_util/specialized_algorithms/destroy/constrained.cc: New
test.
* .../uninitialized_copy/constrained.cc: New test.
* .../uninitialized_default_construct/constrained.cc: New test.
* .../uninitialized_fill/constrained.cc: New test.
* .../uninitialized_move/constrained.cc: New test.
* .../uninitialized_value_construct/constrained.cc: New test.
Diffstat (limited to 'gcc')
0 files changed, 0 insertions, 0 deletions