tmp/tmpgpkkd4ko/{from.md → to.md}
RENAMED
|
@@ -12,13 +12,24 @@ constexpr tuple& operator=(const tuple& u);
|
|
| 12 |
```
|
| 13 |
|
| 14 |
*Effects:* Assigns each element of `u` to the corresponding element of
|
| 15 |
`*this`.
|
| 16 |
|
|
|
|
|
|
|
| 17 |
*Remarks:* This operator is defined as deleted unless
|
| 18 |
`is_copy_assignable_v<``Tᵢ``>` is `true` for all i.
|
| 19 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 20 |
*Returns:* `*this`.
|
| 21 |
|
| 22 |
``` cpp
|
| 23 |
constexpr tuple& operator=(tuple&& u) noexcept(see below);
|
| 24 |
```
|
|
@@ -26,19 +37,31 @@ constexpr tuple& operator=(tuple&& u) noexcept(see below);
|
|
| 26 |
*Constraints:* `is_move_assignable_v<``Tᵢ``>` is `true` for all i.
|
| 27 |
|
| 28 |
*Effects:* For all i, assigns `std::forward<``Tᵢ``>(get<`i`>(u))` to
|
| 29 |
`get<`i`>(*this)`.
|
| 30 |
|
| 31 |
-
*
|
| 32 |
-
|
|
|
|
|
|
|
| 33 |
|
| 34 |
``` cpp
|
| 35 |
is_nothrow_move_assignable_v<Tᵢ>
|
| 36 |
```
|
| 37 |
|
| 38 |
where Tᵢ is the iᵗʰ type in `Types`.
|
| 39 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 40 |
*Returns:* `*this`.
|
| 41 |
|
| 42 |
``` cpp
|
| 43 |
template<class... UTypes> constexpr tuple& operator=(const tuple<UTypes...>& u);
|
| 44 |
```
|
|
@@ -51,10 +74,24 @@ template<class... UTypes> constexpr tuple& operator=(const tuple<UTypes...>& u);
|
|
| 51 |
*Effects:* Assigns each element of `u` to the corresponding element of
|
| 52 |
`*this`.
|
| 53 |
|
| 54 |
*Returns:* `*this`.
|
| 55 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 56 |
``` cpp
|
| 57 |
template<class... UTypes> constexpr tuple& operator=(tuple<UTypes...>&& u);
|
| 58 |
```
|
| 59 |
|
| 60 |
*Constraints:*
|
|
@@ -65,10 +102,24 @@ template<class... UTypes> constexpr tuple& operator=(tuple<UTypes...>&& u);
|
|
| 65 |
*Effects:* For all i, assigns `std::forward<``Uᵢ``>(get<`i`>(u))` to
|
| 66 |
`get<`i`>(*this)`.
|
| 67 |
|
| 68 |
*Returns:* `*this`.
|
| 69 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 70 |
``` cpp
|
| 71 |
template<class U1, class U2> constexpr tuple& operator=(const pair<U1, U2>& u);
|
| 72 |
```
|
| 73 |
|
| 74 |
*Constraints:*
|
|
@@ -80,10 +131,25 @@ template<class U1, class U2> constexpr tuple& operator=(const pair<U1, U2>& u);
|
|
| 80 |
*Effects:* Assigns `u.first` to the first element of `*this` and
|
| 81 |
`u.second` to the second element of `*this`.
|
| 82 |
|
| 83 |
*Returns:* `*this`.
|
| 84 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 85 |
``` cpp
|
| 86 |
template<class U1, class U2> constexpr tuple& operator=(pair<U1, U2>&& u);
|
| 87 |
```
|
| 88 |
|
| 89 |
*Constraints:*
|
|
@@ -96,5 +162,59 @@ template<class U1, class U2> constexpr tuple& operator=(pair<U1, U2>&& u);
|
|
| 96 |
`*this` and
|
| 97 |
`std::forward<U2>(u.second)` to the second element of `*this`.
|
| 98 |
|
| 99 |
*Returns:* `*this`.
|
| 100 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 12 |
```
|
| 13 |
|
| 14 |
*Effects:* Assigns each element of `u` to the corresponding element of
|
| 15 |
`*this`.
|
| 16 |
|
| 17 |
+
*Returns:* `*this`.
|
| 18 |
+
|
| 19 |
*Remarks:* This operator is defined as deleted unless
|
| 20 |
`is_copy_assignable_v<``Tᵢ``>` is `true` for all i.
|
| 21 |
|
| 22 |
+
``` cpp
|
| 23 |
+
constexpr const tuple& operator=(const tuple& u) const;
|
| 24 |
+
```
|
| 25 |
+
|
| 26 |
+
*Constraints:* `(is_copy_assignable_v<const Types> && ...)` is `true`.
|
| 27 |
+
|
| 28 |
+
*Effects:* Assigns each element of `u` to the corresponding element of
|
| 29 |
+
`*this`.
|
| 30 |
+
|
| 31 |
*Returns:* `*this`.
|
| 32 |
|
| 33 |
``` cpp
|
| 34 |
constexpr tuple& operator=(tuple&& u) noexcept(see below);
|
| 35 |
```
|
|
|
|
| 37 |
*Constraints:* `is_move_assignable_v<``Tᵢ``>` is `true` for all i.
|
| 38 |
|
| 39 |
*Effects:* For all i, assigns `std::forward<``Tᵢ``>(get<`i`>(u))` to
|
| 40 |
`get<`i`>(*this)`.
|
| 41 |
|
| 42 |
+
*Returns:* `*this`.
|
| 43 |
+
|
| 44 |
+
*Remarks:* The exception specification is equivalent to the logical of
|
| 45 |
+
the following expressions:
|
| 46 |
|
| 47 |
``` cpp
|
| 48 |
is_nothrow_move_assignable_v<Tᵢ>
|
| 49 |
```
|
| 50 |
|
| 51 |
where Tᵢ is the iᵗʰ type in `Types`.
|
| 52 |
|
| 53 |
+
``` cpp
|
| 54 |
+
constexpr const tuple& operator=(tuple&& u) const;
|
| 55 |
+
```
|
| 56 |
+
|
| 57 |
+
*Constraints:* `(is_assignable_v<const Types&, Types> && ...)` is
|
| 58 |
+
`true`.
|
| 59 |
+
|
| 60 |
+
*Effects:* For all i, assigns `std::forward<T`ᵢ`>(get<`i`>(u))` to
|
| 61 |
+
`get<`i`>(*this)`.
|
| 62 |
+
|
| 63 |
*Returns:* `*this`.
|
| 64 |
|
| 65 |
``` cpp
|
| 66 |
template<class... UTypes> constexpr tuple& operator=(const tuple<UTypes...>& u);
|
| 67 |
```
|
|
|
|
| 74 |
*Effects:* Assigns each element of `u` to the corresponding element of
|
| 75 |
`*this`.
|
| 76 |
|
| 77 |
*Returns:* `*this`.
|
| 78 |
|
| 79 |
+
``` cpp
|
| 80 |
+
template<class... UTypes> constexpr const tuple& operator=(const tuple<UTypes...>& u) const;
|
| 81 |
+
```
|
| 82 |
+
|
| 83 |
+
*Constraints:*
|
| 84 |
+
|
| 85 |
+
- `sizeof...(Types)` equals `sizeof...(UTypes)` and
|
| 86 |
+
- `(is_assignable_v<const Types&, const UTypes&> && ...)` is `true`.
|
| 87 |
+
|
| 88 |
+
*Effects:* Assigns each element of `u` to the corresponding element of
|
| 89 |
+
`*this`.
|
| 90 |
+
|
| 91 |
+
*Returns:* `*this`.
|
| 92 |
+
|
| 93 |
``` cpp
|
| 94 |
template<class... UTypes> constexpr tuple& operator=(tuple<UTypes...>&& u);
|
| 95 |
```
|
| 96 |
|
| 97 |
*Constraints:*
|
|
|
|
| 102 |
*Effects:* For all i, assigns `std::forward<``Uᵢ``>(get<`i`>(u))` to
|
| 103 |
`get<`i`>(*this)`.
|
| 104 |
|
| 105 |
*Returns:* `*this`.
|
| 106 |
|
| 107 |
+
``` cpp
|
| 108 |
+
template<class... UTypes> constexpr const tuple& operator=(tuple<UTypes...>&& u) const;
|
| 109 |
+
```
|
| 110 |
+
|
| 111 |
+
*Constraints:*
|
| 112 |
+
|
| 113 |
+
- `sizeof...(Types)` equals `sizeof...(UTypes)` and
|
| 114 |
+
- `(is_assignable_v<const Types&, UTypes> && ...)` is `true`.
|
| 115 |
+
|
| 116 |
+
*Effects:* For all i, assigns `std::forward<U`ᵢ`>(get<`i`>(u))` to
|
| 117 |
+
`get<`i`>(*this)`.
|
| 118 |
+
|
| 119 |
+
*Returns:* `*this`.
|
| 120 |
+
|
| 121 |
``` cpp
|
| 122 |
template<class U1, class U2> constexpr tuple& operator=(const pair<U1, U2>& u);
|
| 123 |
```
|
| 124 |
|
| 125 |
*Constraints:*
|
|
|
|
| 131 |
*Effects:* Assigns `u.first` to the first element of `*this` and
|
| 132 |
`u.second` to the second element of `*this`.
|
| 133 |
|
| 134 |
*Returns:* `*this`.
|
| 135 |
|
| 136 |
+
``` cpp
|
| 137 |
+
template<class U1, class U2> constexpr const tuple& operator=(const pair<U1, U2>& u) const;
|
| 138 |
+
```
|
| 139 |
+
|
| 140 |
+
*Constraints:*
|
| 141 |
+
|
| 142 |
+
- `sizeof...(Types)` is 2,
|
| 143 |
+
- `is_assignable_v<const ``T₀``&, const U1&>` is `true`, and
|
| 144 |
+
- `is_assignable_v<const ``T₁``&, const U2&>` is `true`.
|
| 145 |
+
|
| 146 |
+
*Effects:* Assigns `u.first` to the first element and `u.second` to the
|
| 147 |
+
second element.
|
| 148 |
+
|
| 149 |
+
*Returns:* `*this`.
|
| 150 |
+
|
| 151 |
``` cpp
|
| 152 |
template<class U1, class U2> constexpr tuple& operator=(pair<U1, U2>&& u);
|
| 153 |
```
|
| 154 |
|
| 155 |
*Constraints:*
|
|
|
|
| 162 |
`*this` and
|
| 163 |
`std::forward<U2>(u.second)` to the second element of `*this`.
|
| 164 |
|
| 165 |
*Returns:* `*this`.
|
| 166 |
|
| 167 |
+
``` cpp
|
| 168 |
+
template<class U1, class U2> constexpr const tuple& operator=(pair<U1, U2>&& u) const;
|
| 169 |
+
```
|
| 170 |
+
|
| 171 |
+
*Constraints:*
|
| 172 |
+
|
| 173 |
+
- `sizeof...(Types)` is 2,
|
| 174 |
+
- `is_assignable_v<const ``T₀``&, U1>` is `true`, and
|
| 175 |
+
- `is_assignable_v<const ``T₁``&, U2>` is `true`.
|
| 176 |
+
|
| 177 |
+
*Effects:* Assigns `std::forward<U1>(u.first)` to the first element
|
| 178 |
+
and
|
| 179 |
+
`std::forward<U2>(u.second)` to the second element.
|
| 180 |
+
|
| 181 |
+
*Returns:* `*this`.
|
| 182 |
+
|
| 183 |
+
``` cpp
|
| 184 |
+
template<tuple-like UTuple>
|
| 185 |
+
constexpr tuple& operator=(UTuple&& u);
|
| 186 |
+
```
|
| 187 |
+
|
| 188 |
+
*Constraints:*
|
| 189 |
+
|
| 190 |
+
- `different-from<UTuple, tuple>` [[range.utility.helpers]] is `true`,
|
| 191 |
+
- `remove_cvref_t<UTuple>` is not a specialization of
|
| 192 |
+
`ranges::subrange`,
|
| 193 |
+
- `sizeof...(Types)` equals `tuple_size_v<remove_cvref_t<UTuple>>`, and,
|
| 194 |
+
- `is_assignable_v<``Tᵢ``&, decltype(get<`i`>(std::forward<UTuple>(u)))>`
|
| 195 |
+
is `true` for all i.
|
| 196 |
+
|
| 197 |
+
*Effects:* For all i, assigns `get<`i`>(std::forward<UTuple>(u))` to
|
| 198 |
+
`get<`i`>(*this)`.
|
| 199 |
+
|
| 200 |
+
*Returns:* `*this`.
|
| 201 |
+
|
| 202 |
+
``` cpp
|
| 203 |
+
template<tuple-like UTuple>
|
| 204 |
+
constexpr const tuple& operator=(UTuple&& u) const;
|
| 205 |
+
```
|
| 206 |
+
|
| 207 |
+
*Constraints:*
|
| 208 |
+
|
| 209 |
+
- `different-from<UTuple, tuple>` [[range.utility.helpers]] is `true`,
|
| 210 |
+
- `remove_cvref_t<UTuple>` is not a specialization of
|
| 211 |
+
`ranges::subrange`,
|
| 212 |
+
- `sizeof...(Types)` equals `tuple_size_v<remove_cvref_t<UTuple>>`, and,
|
| 213 |
+
- `is_assignable_v<const ``Tᵢ``&, decltype(get<`i`>(std::forward<UTuple>(u)))>`
|
| 214 |
+
is `true` for all i.
|
| 215 |
+
|
| 216 |
+
*Effects:* For all i, assigns `get<`i`>(std::forward<UTuple>(u))` to
|
| 217 |
+
`get<`i`>(*this)`.
|
| 218 |
+
|
| 219 |
+
*Returns:* `*this`.
|
| 220 |
+
|