tmp/tmpfgvvowxu/{from.md → to.md}
RENAMED
|
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
### Arithmetic concepts <a id="concepts.arithmetic">[[concepts.arithmetic]]</a>
|
| 2 |
+
|
| 3 |
+
``` cpp
|
| 4 |
+
template<class T>
|
| 5 |
+
concept integral = is_integral_v<T>;
|
| 6 |
+
template<class T>
|
| 7 |
+
concept signed_integral = integral<T> && is_signed_v<T>;
|
| 8 |
+
template<class T>
|
| 9 |
+
concept unsigned_integral = integral<T> && !signed_integral<T>;
|
| 10 |
+
template<class T>
|
| 11 |
+
concept floating_point = is_floating_point_v<T>;
|
| 12 |
+
```
|
| 13 |
+
|
| 14 |
+
[*Note 1*: `signed_integral` can be modeled even by types that are not
|
| 15 |
+
signed integer types [[basic.fundamental]]; for example,
|
| 16 |
+
`char`. — *end note*]
|
| 17 |
+
|
| 18 |
+
[*Note 2*: `unsigned_integral` can be modeled even by types that are
|
| 19 |
+
not unsigned integer types [[basic.fundamental]]; for example,
|
| 20 |
+
`bool`. — *end note*]
|
| 21 |
+
|