blob: 1ed7d6c6ecf5a921180e8e79710387e07379b4b8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
Index: uClibc++-0.2.2/include/limits
===================================================================
--- uClibc++-0.2.2/include/limits (revision 1877)
+++ uClibc++-0.2.2/include/limits (revision 1878)
@@ -143,6 +143,53 @@
static T signaling_NaN();
};
+template <> class numeric_limits<bool> {
+public:
+ typedef bool T;
+ // General -- meaningful for all specializations.
+ static const bool is_specialized = true;
+ static T min(){
+ return false;
+ }
+ static T max(){
+ return true;
+ }
+ static const int radix = 2;
+ static const int digits = 1;
+ static const int digits10 = 0;
+ static const bool is_signed = false;
+ static const bool is_integer = true;
+ static const bool is_exact = true;
+ static const bool traps = false;
+ static const bool is_modulo = false;
+ static const bool is_bounded = true;
+
+ // Floating point specific.
+
+ static T epsilon(){
+ return 0;
+ }
+ static T round_error(){
+ return 0;
+ }
+ static const int min_exponent10 = 0;
+ static const int max_exponent10 = 0;
+ static const int min_exponent = 0;
+
+ static const int max_exponent = 0;
+ static const bool has_infinity = false;
+ static const bool has_quiet_NaN = false;
+ static const bool has_signaling_NaN = false;
+ static const bool is_iec559 = false;
+ static const bool has_denorm = false;
+ static const bool tinyness_before = false;
+ static const float_round_style round_style = round_indeterminate;
+ static T denorm_min();
+ static T infinity();
+ static T quiet_NaN();
+ static T signaling_NaN();
+};
+
template <> class numeric_limits<unsigned char> {
public:
typedef unsigned char T;
@@ -567,6 +614,7 @@
};
template <> class numeric_limits<double> {
+public:
typedef double numeric_type;
static const bool is_specialized = true;
|