提交 18dde007 编写于 作者: S Szabolcs Nagy 提交者: Rich Felker

add C11 floating-point characteristic macros to float.h

C11 introduced *_DECIMAL_DIG and *_HAS_SUBNORM macros.
上级 8d998a7b
...@@ -11,8 +11,10 @@ ...@@ -11,8 +11,10 @@
#define FLT_MANT_DIG 24 #define FLT_MANT_DIG 24
#define FLT_MIN_EXP (-125) #define FLT_MIN_EXP (-125)
#define FLT_MAX_EXP 128 #define FLT_MAX_EXP 128
#define FLT_HAS_SUBNORM 1
#define FLT_DIG 6 #define FLT_DIG 6
#define FLT_DECIMAL_DIG 9
#define FLT_MIN_10_EXP (-37) #define FLT_MIN_10_EXP (-37)
#define FLT_MAX_10_EXP 38 #define FLT_MAX_10_EXP 38
...@@ -24,11 +26,16 @@ ...@@ -24,11 +26,16 @@
#define DBL_MANT_DIG 53 #define DBL_MANT_DIG 53
#define DBL_MIN_EXP (-1021) #define DBL_MIN_EXP (-1021)
#define DBL_MAX_EXP 1024 #define DBL_MAX_EXP 1024
#define DBL_HAS_SUBNORM 1
#define DBL_DIG 15 #define DBL_DIG 15
#define DBL_DECIMAL_DIG 17
#define DBL_MIN_10_EXP (-307) #define DBL_MIN_10_EXP (-307)
#define DBL_MAX_10_EXP 308 #define DBL_MAX_10_EXP 308
#define LDBL_HAS_SUBNORM 1
#define LDBL_DECIMAL_DIG DECIMAL_DIG
#include <bits/float.h> #include <bits/float.h>
#endif #endif
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册