From Jason Turner

[valarray.comparison]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpe9rkpczm/{from.md → to.md} +17 -19
tmp/tmpe9rkpczm/{from.md → to.md} RENAMED
@@ -17,22 +17,20 @@ template<class T> valarray<bool> operator&&
17
  (const valarray<T>&, const valarray<T>&);
18
  template<class T> valarray<bool> operator||
19
  (const valarray<T>&, const valarray<T>&);
20
  ```
21
 
22
- Each of these operators may only be instantiated for a type `T` to which
23
- the indicated operator can be applied and for which the indicated
24
- operator returns a value which is of type `bool` or which can be
25
- unambiguously implicitly converted to type `bool`.
 
26
 
27
- Each of these operators returns a `bool` array whose length is equal to
28
- the length of the array arguments. Each element of the returned array is
29
- initialized with the result of applying the indicated operator to the
30
- corresponding elements of the argument arrays.
31
-
32
- If the two array arguments do not have the same length, the behavior is
33
- undefined.
34
 
35
  ``` cpp
36
  template<class T> valarray<bool> operator==(const valarray<T>&, const T&);
37
  template<class T> valarray<bool> operator==(const T&, const valarray<T>&);
38
  template<class T> valarray<bool> operator!=(const valarray<T>&, const T&);
@@ -49,15 +47,15 @@ template<class T> valarray<bool> operator&&(const valarray<T>&, const T&);
49
  template<class T> valarray<bool> operator&&(const T&, const valarray<T>&);
50
  template<class T> valarray<bool> operator||(const valarray<T>&, const T&);
51
  template<class T> valarray<bool> operator||(const T&, const valarray<T>&);
52
  ```
53
 
54
- Each of these operators may only be instantiated for a type `T` to which
55
- the indicated operator can be applied and for which the indicated
56
- operator returns a value which is of type `bool` or which can be
57
- unambiguously implicitly converted to type `bool`.
58
 
59
- Each of these operators returns a `bool` array whose length is equal to
60
- the length of the array argument. Each element of the returned array is
61
- initialized with the result of applying the indicated operator to the
62
- corresponding element of the array and the non-array argument.
63
 
 
17
  (const valarray<T>&, const valarray<T>&);
18
  template<class T> valarray<bool> operator||
19
  (const valarray<T>&, const valarray<T>&);
20
  ```
21
 
22
+ *Requires:* Each of these operators may only be instantiated for a type
23
+ `T` to which the indicated operator can be applied and for which the
24
+ indicated operator returns a value which is of type `bool` or which can
25
+ be unambiguously implicitly converted to type `bool`. The two array
26
+ arguments have the same length.
27
 
28
+ *Returns:* A `valarray<bool>` whose length is equal to the length of the
29
+ array arguments. Each element of the returned array is initialized with
30
+ the result of applying the indicated operator to the corresponding
31
+ elements of the argument arrays.
 
 
 
32
 
33
  ``` cpp
34
  template<class T> valarray<bool> operator==(const valarray<T>&, const T&);
35
  template<class T> valarray<bool> operator==(const T&, const valarray<T>&);
36
  template<class T> valarray<bool> operator!=(const valarray<T>&, const T&);
 
47
  template<class T> valarray<bool> operator&&(const T&, const valarray<T>&);
48
  template<class T> valarray<bool> operator||(const valarray<T>&, const T&);
49
  template<class T> valarray<bool> operator||(const T&, const valarray<T>&);
50
  ```
51
 
52
+ *Requires:* Each of these operators may only be instantiated for a type
53
+ `T` to which the indicated operator can be applied and for which the
54
+ indicated operator returns a value which is of type `bool` or which can
55
+ be unambiguously implicitly converted to type `bool`.
56
 
57
+ *Returns:* A `valarray<bool>` whose length is equal to the length of the
58
+ array argument. Each element of the returned array is initialized with
59
+ the result of applying the indicated operator to the corresponding
60
+ element of the array and the non-array argument.
61