tmp/tmp82lk7uk6/{from.md → to.md}
RENAMED
|
@@ -22,10 +22,21 @@ template<class R, copy_constructible F>
|
|
| 22 |
requires invocable<F&> && output_range<R, invoke_result_t<F&>>
|
| 23 |
constexpr borrowed_iterator_t<R> ranges::generate(R&& r, F gen);
|
| 24 |
template<input_or_output_iterator O, copy_constructible F>
|
| 25 |
requires invocable<F&> && indirectly_writable<O, invoke_result_t<F&>>
|
| 26 |
constexpr O ranges::generate_n(O first, iter_difference_t<O> n, F gen);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 27 |
```
|
| 28 |
|
| 29 |
Let N be max(0, `n`) for the `generate_n` algorithms, and `last - first`
|
| 30 |
for the `generate` algorithms.
|
| 31 |
|
|
@@ -37,5 +48,8 @@ through each iterator in the range \[`first`, `first + `N).
|
|
| 37 |
|
| 38 |
*Returns:* `first + `N.
|
| 39 |
|
| 40 |
*Complexity:* Exactly N evaluations of `gen()` and assignments.
|
| 41 |
|
|
|
|
|
|
|
|
|
|
|
|
| 22 |
requires invocable<F&> && output_range<R, invoke_result_t<F&>>
|
| 23 |
constexpr borrowed_iterator_t<R> ranges::generate(R&& r, F gen);
|
| 24 |
template<input_or_output_iterator O, copy_constructible F>
|
| 25 |
requires invocable<F&> && indirectly_writable<O, invoke_result_t<F&>>
|
| 26 |
constexpr O ranges::generate_n(O first, iter_difference_t<O> n, F gen);
|
| 27 |
+
|
| 28 |
+
template<execution-policy Ep, random_access_iterator O, sized_sentinel_for<O> S,
|
| 29 |
+
copy_constructible F>
|
| 30 |
+
requires invocable<F&> && indirectly_writable<O, invoke_result_t<F&>>
|
| 31 |
+
O ranges::generate(Ep&& exec, O first, S last, F gen);
|
| 32 |
+
template<execution-policy Ep, sized-random-access-range R, copy_constructible F>
|
| 33 |
+
requires invocable<F&> && indirectly_writable<iterator_t<R>, invoke_result_t<F&>>
|
| 34 |
+
borrowed_iterator_t<R> ranges::generate(Ep&& exec, R&& r, F gen);
|
| 35 |
+
template<execution-policy Ep, random_access_iterator O, copy_constructible F>
|
| 36 |
+
requires invocable<F&> && indirectly_writable<O, invoke_result_t<F&>>
|
| 37 |
+
O ranges::generate_n(Ep&& exec, O first, iter_difference_t<O> n, F gen);
|
| 38 |
```
|
| 39 |
|
| 40 |
Let N be max(0, `n`) for the `generate_n` algorithms, and `last - first`
|
| 41 |
for the `generate` algorithms.
|
| 42 |
|
|
|
|
| 48 |
|
| 49 |
*Returns:* `first + `N.
|
| 50 |
|
| 51 |
*Complexity:* Exactly N evaluations of `gen()` and assignments.
|
| 52 |
|
| 53 |
+
*Remarks:* `gen` may modify objects via its arguments for parallel
|
| 54 |
+
algorithm overloads [[algorithms.parallel.user]].
|
| 55 |
+
|