tmp/tmpeshg7xo9/{from.md → to.md}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
| 1 |
-
####
|
| 2 |
|
| 3 |
``` cpp
|
| 4 |
valarray& operator*= (const valarray& v);
|
| 5 |
valarray& operator/= (const valarray& v);
|
| 6 |
valarray& operator%= (const valarray& v);
|
|
@@ -11,15 +11,18 @@ valarray& operator&= (const valarray& v);
|
|
| 11 |
valarray& operator|= (const valarray& v);
|
| 12 |
valarray& operator<<=(const valarray& v);
|
| 13 |
valarray& operator>>=(const valarray& v);
|
| 14 |
```
|
| 15 |
|
| 16 |
-
*
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
|
|
|
|
|
|
|
|
|
| 21 |
|
| 22 |
*Effects:* Each of these operators performs the indicated operation on
|
| 23 |
each of the elements of `*this` and the corresponding element of `v`.
|
| 24 |
|
| 25 |
*Returns:* `*this`.
|
|
@@ -38,13 +41,12 @@ valarray& operator&= (const T& v);
|
|
| 38 |
valarray& operator|= (const T& v);
|
| 39 |
valarray& operator<<=(const T& v);
|
| 40 |
valarray& operator>>=(const T& v);
|
| 41 |
```
|
| 42 |
|
| 43 |
-
*
|
| 44 |
-
`T`
|
| 45 |
-
`T`.
|
| 46 |
|
| 47 |
*Effects:* Each of these operators applies the indicated operation to
|
| 48 |
each element of `*this` and `v`.
|
| 49 |
|
| 50 |
*Returns:* `*this`
|
|
|
|
| 1 |
+
#### Compound assignment <a id="valarray.cassign">[[valarray.cassign]]</a>
|
| 2 |
|
| 3 |
``` cpp
|
| 4 |
valarray& operator*= (const valarray& v);
|
| 5 |
valarray& operator/= (const valarray& v);
|
| 6 |
valarray& operator%= (const valarray& v);
|
|
|
|
| 11 |
valarray& operator|= (const valarray& v);
|
| 12 |
valarray& operator<<=(const valarray& v);
|
| 13 |
valarray& operator>>=(const valarray& v);
|
| 14 |
```
|
| 15 |
|
| 16 |
+
*Mandates:* The indicated operator can be applied to two operands of
|
| 17 |
+
type `T`.
|
| 18 |
+
|
| 19 |
+
*Preconditions:* `size() == v.size()` is `true`.
|
| 20 |
+
|
| 21 |
+
The value of an element in the left-hand side of a valarray compound
|
| 22 |
+
assignment operator does not depend on the value of another element in
|
| 23 |
+
that left hand side.
|
| 24 |
|
| 25 |
*Effects:* Each of these operators performs the indicated operation on
|
| 26 |
each of the elements of `*this` and the corresponding element of `v`.
|
| 27 |
|
| 28 |
*Returns:* `*this`.
|
|
|
|
| 41 |
valarray& operator|= (const T& v);
|
| 42 |
valarray& operator<<=(const T& v);
|
| 43 |
valarray& operator>>=(const T& v);
|
| 44 |
```
|
| 45 |
|
| 46 |
+
*Mandates:* The indicated operator can be applied to two operands of
|
| 47 |
+
type `T`.
|
|
|
|
| 48 |
|
| 49 |
*Effects:* Each of these operators applies the indicated operation to
|
| 50 |
each element of `*this` and `v`.
|
| 51 |
|
| 52 |
*Returns:* `*this`
|