From Jason Turner

[optional.relops]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpy8cemtn6/{from.md → to.md} +10 -10
tmp/tmpy8cemtn6/{from.md → to.md} RENAMED
@@ -2,12 +2,12 @@
2
 
3
  ``` cpp
4
  template<class T, class U> constexpr bool operator==(const optional<T>& x, const optional<U>& y);
5
  ```
6
 
7
- *Mandates:* The expression `*x == *y` is well-formed and its result is
8
- convertible to `bool`.
9
 
10
  [*Note 1*: `T` need not be *Cpp17EqualityComparable*. — *end note*]
11
 
12
  *Returns:* If `x.has_value() != y.has_value()`, `false`; otherwise if
13
  `x.has_value() == false`, `true`; otherwise `*x == *y`.
@@ -17,12 +17,12 @@ convertible to `bool`.
17
 
18
  ``` cpp
19
  template<class T, class U> constexpr bool operator!=(const optional<T>& x, const optional<U>& y);
20
  ```
21
 
22
- *Mandates:* The expression `*x != *y` is well-formed and its result is
23
- convertible to `bool`.
24
 
25
  *Returns:* If `x.has_value() != y.has_value()`, `true`; otherwise, if
26
  `x.has_value() == false`, `false`; otherwise `*x != *y`.
27
 
28
  *Remarks:* Specializations of this function template for which
@@ -30,11 +30,11 @@ convertible to `bool`.
30
 
31
  ``` cpp
32
  template<class T, class U> constexpr bool operator<(const optional<T>& x, const optional<U>& y);
33
  ```
34
 
35
- *Mandates:* `*x < *y` is well-formed and its result is convertible to
36
  `bool`.
37
 
38
  *Returns:* If `!y`, `false`; otherwise, if `!x`, `true`; otherwise
39
  `*x < *y`.
40
 
@@ -43,11 +43,11 @@ is a core constant expression are constexpr functions.
43
 
44
  ``` cpp
45
  template<class T, class U> constexpr bool operator>(const optional<T>& x, const optional<U>& y);
46
  ```
47
 
48
- *Mandates:* The expression `*x > *y` is well-formed and its result is
49
  convertible to `bool`.
50
 
51
  *Returns:* If `!x`, `false`; otherwise, if `!y`, `true`; otherwise
52
  `*x > *y`.
53
 
@@ -56,12 +56,12 @@ is a core constant expression are constexpr functions.
56
 
57
  ``` cpp
58
  template<class T, class U> constexpr bool operator<=(const optional<T>& x, const optional<U>& y);
59
  ```
60
 
61
- *Mandates:* The expression `*x <= *y` is well-formed and its result is
62
- convertible to `bool`.
63
 
64
  *Returns:* If `!x`, `true`; otherwise, if `!y`, `false`; otherwise
65
  `*x <= *y`.
66
 
67
  *Remarks:* Specializations of this function template for which
@@ -69,12 +69,12 @@ convertible to `bool`.
69
 
70
  ``` cpp
71
  template<class T, class U> constexpr bool operator>=(const optional<T>& x, const optional<U>& y);
72
  ```
73
 
74
- *Mandates:* The expression `*x >= *y` is well-formed and its result is
75
- convertible to `bool`.
76
 
77
  *Returns:* If `!y`, `true`; otherwise, if `!x`, `false`; otherwise
78
  `*x >= *y`.
79
 
80
  *Remarks:* Specializations of this function template for which
 
2
 
3
  ``` cpp
4
  template<class T, class U> constexpr bool operator==(const optional<T>& x, const optional<U>& y);
5
  ```
6
 
7
+ *Constraints:* The expression `*x == *y` is well-formed and its result
8
+ is convertible to `bool`.
9
 
10
  [*Note 1*: `T` need not be *Cpp17EqualityComparable*. — *end note*]
11
 
12
  *Returns:* If `x.has_value() != y.has_value()`, `false`; otherwise if
13
  `x.has_value() == false`, `true`; otherwise `*x == *y`.
 
17
 
18
  ``` cpp
19
  template<class T, class U> constexpr bool operator!=(const optional<T>& x, const optional<U>& y);
20
  ```
21
 
22
+ *Constraints:* The expression `*x != *y` is well-formed and its result
23
+ is convertible to `bool`.
24
 
25
  *Returns:* If `x.has_value() != y.has_value()`, `true`; otherwise, if
26
  `x.has_value() == false`, `false`; otherwise `*x != *y`.
27
 
28
  *Remarks:* Specializations of this function template for which
 
30
 
31
  ``` cpp
32
  template<class T, class U> constexpr bool operator<(const optional<T>& x, const optional<U>& y);
33
  ```
34
 
35
+ *Constraints:* `*x < *y` is well-formed and its result is convertible to
36
  `bool`.
37
 
38
  *Returns:* If `!y`, `false`; otherwise, if `!x`, `true`; otherwise
39
  `*x < *y`.
40
 
 
43
 
44
  ``` cpp
45
  template<class T, class U> constexpr bool operator>(const optional<T>& x, const optional<U>& y);
46
  ```
47
 
48
+ *Constraints:* The expression `*x > *y` is well-formed and its result is
49
  convertible to `bool`.
50
 
51
  *Returns:* If `!x`, `false`; otherwise, if `!y`, `true`; otherwise
52
  `*x > *y`.
53
 
 
56
 
57
  ``` cpp
58
  template<class T, class U> constexpr bool operator<=(const optional<T>& x, const optional<U>& y);
59
  ```
60
 
61
+ *Constraints:* The expression `*x <= *y` is well-formed and its result
62
+ is convertible to `bool`.
63
 
64
  *Returns:* If `!x`, `true`; otherwise, if `!y`, `false`; otherwise
65
  `*x <= *y`.
66
 
67
  *Remarks:* Specializations of this function template for which
 
69
 
70
  ``` cpp
71
  template<class T, class U> constexpr bool operator>=(const optional<T>& x, const optional<U>& y);
72
  ```
73
 
74
+ *Constraints:* The expression `*x >= *y` is well-formed and its result
75
+ is convertible to `bool`.
76
 
77
  *Returns:* If `!y`, `true`; otherwise, if `!x`, `false`; otherwise
78
  `*x >= *y`.
79
 
80
  *Remarks:* Specializations of this function template for which