From Jason Turner

[time.duration.comparisons]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpojr_ef68/{from.md → to.md} +20 -19
tmp/tmpojr_ef68/{from.md → to.md} RENAMED
@@ -1,6 +1,6 @@
1
- #### `duration` comparisons <a id="time.duration.comparisons">[[time.duration.comparisons]]</a>
2
 
3
  In the function descriptions that follow, `CT` represents
4
  `common_type_t<A, B>`, where `A` and `B` are the types of the two
5
  arguments to the function.
6
 
@@ -8,47 +8,48 @@ arguments to the function.
8
  template<class Rep1, class Period1, class Rep2, class Period2>
9
  constexpr bool operator==(const duration<Rep1, Period1>& lhs,
10
  const duration<Rep2, Period2>& rhs);
11
  ```
12
 
13
- *Returns:* *`CT`*`(lhs).count() == `*`CT`*`(rhs).count()`.
14
-
15
- ``` cpp
16
- template <class Rep1, class Period1, class Rep2, class Period2>
17
- constexpr bool operator!=(const duration<Rep1, Period1>& lhs,
18
- const duration<Rep2, Period2>& rhs);
19
- ```
20
-
21
- *Returns:* `!(lhs == rhs)`.
22
 
23
  ``` cpp
24
  template<class Rep1, class Period1, class Rep2, class Period2>
25
  constexpr bool operator<(const duration<Rep1, Period1>& lhs,
26
  const duration<Rep2, Period2>& rhs);
27
  ```
28
 
29
- *Returns:* *`CT`*`(lhs).count() < `*`CT`*`(rhs).count()`.
30
-
31
- ``` cpp
32
- template <class Rep1, class Period1, class Rep2, class Period2>
33
- constexpr bool operator<=(const duration<Rep1, Period1>& lhs,
34
- const duration<Rep2, Period2>& rhs);
35
- ```
36
-
37
- *Returns:* `!(rhs < lhs)`.
38
 
39
  ``` cpp
40
  template<class Rep1, class Period1, class Rep2, class Period2>
41
  constexpr bool operator>(const duration<Rep1, Period1>& lhs,
42
  const duration<Rep2, Period2>& rhs);
43
  ```
44
 
45
  *Returns:* `rhs < lhs`.
46
 
 
 
 
 
 
 
 
 
47
  ``` cpp
48
  template<class Rep1, class Period1, class Rep2, class Period2>
49
  constexpr bool operator>=(const duration<Rep1, Period1>& lhs,
50
  const duration<Rep2, Period2>& rhs);
51
  ```
52
 
53
  *Returns:* `!(lhs < rhs)`.
54
 
 
 
 
 
 
 
 
 
 
 
1
+ ### Comparisons <a id="time.duration.comparisons">[[time.duration.comparisons]]</a>
2
 
3
  In the function descriptions that follow, `CT` represents
4
  `common_type_t<A, B>`, where `A` and `B` are the types of the two
5
  arguments to the function.
6
 
 
8
  template<class Rep1, class Period1, class Rep2, class Period2>
9
  constexpr bool operator==(const duration<Rep1, Period1>& lhs,
10
  const duration<Rep2, Period2>& rhs);
11
  ```
12
 
13
+ *Returns:* `CT(lhs).count() == CT(rhs).count()`.
 
 
 
 
 
 
 
 
14
 
15
  ``` cpp
16
  template<class Rep1, class Period1, class Rep2, class Period2>
17
  constexpr bool operator<(const duration<Rep1, Period1>& lhs,
18
  const duration<Rep2, Period2>& rhs);
19
  ```
20
 
21
+ *Returns:* `CT(lhs).count() < CT(rhs).count()`.
 
 
 
 
 
 
 
 
22
 
23
  ``` cpp
24
  template<class Rep1, class Period1, class Rep2, class Period2>
25
  constexpr bool operator>(const duration<Rep1, Period1>& lhs,
26
  const duration<Rep2, Period2>& rhs);
27
  ```
28
 
29
  *Returns:* `rhs < lhs`.
30
 
31
+ ``` cpp
32
+ template<class Rep1, class Period1, class Rep2, class Period2>
33
+ constexpr bool operator<=(const duration<Rep1, Period1>& lhs,
34
+ const duration<Rep2, Period2>& rhs);
35
+ ```
36
+
37
+ *Returns:* `!(rhs < lhs)`.
38
+
39
  ``` cpp
40
  template<class Rep1, class Period1, class Rep2, class Period2>
41
  constexpr bool operator>=(const duration<Rep1, Period1>& lhs,
42
  const duration<Rep2, Period2>& rhs);
43
  ```
44
 
45
  *Returns:* `!(lhs < rhs)`.
46
 
47
+ ``` cpp
48
+ template<class Rep1, class Period1, class Rep2, class Period2>
49
+ requires three_way_comparable<typename CT::rep>
50
+ constexpr auto operator<=>(const duration<Rep1, Period1>& lhs,
51
+ const duration<Rep2, Period2>& rhs);
52
+ ```
53
+
54
+ *Returns:* `CT(lhs).count() <=> CT(rhs).count()`.
55
+