mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-20 19:45:12 +00:00
AK: Add epsilon() to NumericLimits for float, double, long double
This commit is contained in:
parent
605848787b
commit
0a557d65a0
Notes:
sideshowbarker
2024-07-18 18:33:15 +09:00
Author: https://github.com/sunverwerth Commit: https://github.com/SerenityOS/serenity/commit/0a557d65a0b Pull-request: https://github.com/SerenityOS/serenity/pull/6375 Reviewed-by: https://github.com/Hendiadyoin1 Reviewed-by: https://github.com/IdanHo Reviewed-by: https://github.com/Quaker762 Reviewed-by: https://github.com/alimpfard Reviewed-by: https://github.com/ccapitalK Reviewed-by: https://github.com/gmta
1 changed files with 3 additions and 0 deletions
|
@ -103,6 +103,7 @@ template<>
|
|||
struct NumericLimits<float> {
|
||||
static constexpr float min() { return __FLT_MIN__; }
|
||||
static constexpr float max() { return __FLT_MAX__; }
|
||||
static constexpr float epsilon() { return __FLT_EPSILON__; }
|
||||
static constexpr bool is_signed() { return true; }
|
||||
};
|
||||
|
||||
|
@ -110,6 +111,7 @@ template<>
|
|||
struct NumericLimits<double> {
|
||||
static constexpr double min() { return __DBL_MIN__; }
|
||||
static constexpr double max() { return __DBL_MAX__; }
|
||||
static constexpr double epsilon() { return __DBL_EPSILON__; }
|
||||
static constexpr bool is_signed() { return true; }
|
||||
};
|
||||
|
||||
|
@ -117,6 +119,7 @@ template<>
|
|||
struct NumericLimits<long double> {
|
||||
static constexpr long double min() { return __LDBL_MIN__; }
|
||||
static constexpr long double max() { return __LDBL_MAX__; }
|
||||
static constexpr long double epsilon() { return __LDBL_EPSILON__; }
|
||||
static constexpr bool is_signed() { return true; }
|
||||
};
|
||||
#endif
|
||||
|
|
Loading…
Add table
Reference in a new issue