Skip to content
Commit 3f630cff authored by Konstantin Varlamov's avatar Konstantin Varlamov
Browse files

[libc++][ranges] Implement ranges::uninitialized_default_construct{,_n}.

Defined in [`specialized.algorithms`](wg21.link/specialized.algorithms).

Also:
- refactor the existing non-range implementation so that most of it
  can be shared between the range-based and non-range-based algorithms;
- remove an existing test for the non-range version of
  `uninitialized_default_construct{,_n}` that likely triggered undefined
  behavior (it read the values of built-ins after default-initializing
  them, essentially reading uninitialized memory).

Reviewed By: #libc, Quuxplusone, ldionne

Differential Revision: https://reviews.llvm.org/D115315
parent 624f12d3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment