tmp/tmptd1nk6my/{from.md → to.md}
RENAMED
|
@@ -1,21 +1,28 @@
|
|
| 1 |
#### `sort` <a id="sort">[[sort]]</a>
|
| 2 |
|
| 3 |
``` cpp
|
| 4 |
template<class RandomAccessIterator>
|
| 5 |
void sort(RandomAccessIterator first, RandomAccessIterator last);
|
|
|
|
|
|
|
|
|
|
| 6 |
|
| 7 |
template<class RandomAccessIterator, class Compare>
|
| 8 |
void sort(RandomAccessIterator first, RandomAccessIterator last,
|
| 9 |
Compare comp);
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
```
|
| 11 |
|
| 12 |
-
*Effects:* Sorts the elements in the range \[`first`, `last`).
|
| 13 |
-
|
| 14 |
*Requires:* `RandomAccessIterator` shall satisfy the requirements of
|
| 15 |
`ValueSwappable` ([[swappable.requirements]]). The type of `*first`
|
| 16 |
shall satisfy the requirements of `MoveConstructible`
|
| 17 |
-
(Table [[moveconstructible]]) and of `MoveAssignable`
|
| 18 |
-
(Table [[moveassignable]]).
|
| 19 |
|
| 20 |
-
*
|
|
|
|
|
|
|
| 21 |
|
|
|
|
| 1 |
#### `sort` <a id="sort">[[sort]]</a>
|
| 2 |
|
| 3 |
``` cpp
|
| 4 |
template<class RandomAccessIterator>
|
| 5 |
void sort(RandomAccessIterator first, RandomAccessIterator last);
|
| 6 |
+
template<class ExecutionPolicy, class RandomAccessIterator>
|
| 7 |
+
void sort(ExecutionPolicy&& exec,
|
| 8 |
+
RandomAccessIterator first, RandomAccessIterator last);
|
| 9 |
|
| 10 |
template<class RandomAccessIterator, class Compare>
|
| 11 |
void sort(RandomAccessIterator first, RandomAccessIterator last,
|
| 12 |
Compare comp);
|
| 13 |
+
template<class ExecutionPolicy, class RandomAccessIterator, class Compare>
|
| 14 |
+
void sort(ExecutionPolicy&& exec,
|
| 15 |
+
RandomAccessIterator first, RandomAccessIterator last,
|
| 16 |
+
Compare comp);
|
| 17 |
```
|
| 18 |
|
|
|
|
|
|
|
| 19 |
*Requires:* `RandomAccessIterator` shall satisfy the requirements of
|
| 20 |
`ValueSwappable` ([[swappable.requirements]]). The type of `*first`
|
| 21 |
shall satisfy the requirements of `MoveConstructible`
|
| 22 |
+
(Table [[tab:moveconstructible]]) and of `MoveAssignable`
|
| 23 |
+
(Table [[tab:moveassignable]]).
|
| 24 |
|
| 25 |
+
*Effects:* Sorts the elements in the range \[`first`, `last`).
|
| 26 |
+
|
| 27 |
+
*Complexity:* 𝑂(N log N) comparisons, where N = `last - first`.
|
| 28 |
|