diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2009-08-20 14:17:19 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2009-08-20 16:58:04 +0000 |
commit | 32d225be6fb18e01f33546c64f3ba126fd3e9410 (patch) | |
tree | 78923a0a6e0281824ee7c88cc01f4848399cb8a4 /main/uclibc++/007-numeric_limits.patch | |
parent | 1444ddae645e1206190da7319a00413ffafd222b (diff) | |
download | aports-32d225be6fb18e01f33546c64f3ba126fd3e9410.tar.bz2 aports-32d225be6fb18e01f33546c64f3ba126fd3e9410.tar.xz |
main/uclibc++: import patches from openwrt
https://dev.openwrt.org/browser/packages/libs/uclibc%2B%2B/patches
Diffstat (limited to 'main/uclibc++/007-numeric_limits.patch')
-rw-r--r-- | main/uclibc++/007-numeric_limits.patch | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/main/uclibc++/007-numeric_limits.patch b/main/uclibc++/007-numeric_limits.patch new file mode 100644 index 0000000000..1ed7d6c6ec --- /dev/null +++ b/main/uclibc++/007-numeric_limits.patch @@ -0,0 +1,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; |