re PR libstdc++/77619 (uninitialized_meow_construct and friends not exception safe)
authorVille Voutilainen <ville.voutilainen@gmail.com>
Tue, 20 Sep 2016 15:15:36 +0000 (18:15 +0300)
committerVille Voutilainen <ville@gcc.gnu.org>
Tue, 20 Sep 2016 15:15:36 +0000 (18:15 +0300)
commit377f30c00f3b8b8b0da748dbb9d988fa67a8ec2f
tree356ee8f4d2f55dc7174b1dfcb39e330821546d25
parent7d9cf8015969054f044ee815f0308e7130c59b83
re PR libstdc++/77619 (uninitialized_meow_construct and friends not exception safe)

PR libstdc++/77619
* include/bits/stl_construct.h: (_Construct_novalue): New.
(_Destroy_n_aux, _Destroy_n): New.
* include/bits/stl_uninitialized.h: (type_traits):
New include in C++11 mode.
(__uninitialized_default_novalue_1): New.
(__uninitialized_default_novalue_n_1): Likewise.
(__uninitialized_default_novalue): Likewise.
(__uninitialized_default_novalue_n): Likewise.
(__uninitialized_copy_n_pair): Likewise.
(uninitialized_default_construct):
Use __uninitialized_default_novalue.
(uninitialized_default_construct_n):
Use __uninitialized_default_novalue_n.
(uninitialized_value_construct): Use __uninitialized_default.
(uninitialized_value_construct_n): Use __uninitialized_default_n.
(uninitialized_move): Use uninitialized_copy.
(uninitialized_move_n): Use __uninitialized_copy_n_pair.
(destroy_at): Use _Destroy.
(destroy): Likewise.
(destroy_n): Likewise.
* testsuite/20_util/specialized_algorithms/
memory_management_tools/1.cc: Add tests for exceptions,
add tests for trivial cases for construct and move.

From-SVN: r240264
libstdc++-v3/ChangeLog
libstdc++-v3/include/bits/stl_construct.h
libstdc++-v3/include/bits/stl_uninitialized.h
libstdc++-v3/testsuite/20_util/specialized_algorithms/memory_management_tools/1.cc