Hide FLT_EVAL_METHOD and DECIMAL_DIG in pre-C99 compilation

environments.

PR:		63935
Submitted by:	Stefan Farfeleder <stefan@fafoe.narf.at>
This commit is contained in:
das 2004-04-25 02:36:29 +00:00
parent 8923214f7d
commit bea8ee27aa
6 changed files with 18 additions and 0 deletions

View File

@ -41,8 +41,10 @@ __END_DECLS
#define FLT_RADIX 2 /* b */ #define FLT_RADIX 2 /* b */
#define FLT_ROUNDS __flt_rounds() #define FLT_ROUNDS __flt_rounds()
#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD 0 /* no promotions */ #define FLT_EVAL_METHOD 0 /* no promotions */
#define DECIMAL_DIG 17 /* max precision in decimal digits */ #define DECIMAL_DIG 17 /* max precision in decimal digits */
#endif
#define FLT_MANT_DIG 24 /* p */ #define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */ #define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */

View File

@ -33,10 +33,14 @@
#ifndef _MACHINE_FLOAT_H_ #ifndef _MACHINE_FLOAT_H_
#define _MACHINE_FLOAT_H_ 1 #define _MACHINE_FLOAT_H_ 1
#include <sys/cdefs.h>
#define FLT_RADIX 2 /* b */ #define FLT_RADIX 2 /* b */
#define FLT_ROUNDS 1 /* FP addition rounds to nearest */ #define FLT_ROUNDS 1 /* FP addition rounds to nearest */
#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD (-1) /* i387 semantics are...interesting */ #define FLT_EVAL_METHOD (-1) /* i387 semantics are...interesting */
#define DECIMAL_DIG 21 /* max precision in decimal digits */ #define DECIMAL_DIG 21 /* max precision in decimal digits */
#endif
#define FLT_MANT_DIG 24 /* p */ #define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */ #define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */

View File

@ -33,10 +33,14 @@
#ifndef _MACHINE_FLOAT_H_ #ifndef _MACHINE_FLOAT_H_
#define _MACHINE_FLOAT_H_ 1 #define _MACHINE_FLOAT_H_ 1
#include <sys/cdefs.h>
#define FLT_RADIX 2 /* b */ #define FLT_RADIX 2 /* b */
#define FLT_ROUNDS 1 /* FP addition rounds to nearest */ #define FLT_ROUNDS 1 /* FP addition rounds to nearest */
#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD (-1) /* i387 semantics are...interesting */ #define FLT_EVAL_METHOD (-1) /* i387 semantics are...interesting */
#define DECIMAL_DIG 21 /* max precision in decimal digits */ #define DECIMAL_DIG 21 /* max precision in decimal digits */
#endif
#define FLT_MANT_DIG 24 /* p */ #define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */ #define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */

View File

@ -37,8 +37,10 @@
#define FLT_RADIX 2 /* b */ #define FLT_RADIX 2 /* b */
#define FLT_ROUNDS 1 /* FP addition rounds to nearest */ #define FLT_ROUNDS 1 /* FP addition rounds to nearest */
#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD 0 /* no promotions */ #define FLT_EVAL_METHOD 0 /* no promotions */
#define DECIMAL_DIG 35 /* max precision in decimal digits */ #define DECIMAL_DIG 35 /* max precision in decimal digits */
#endif
#define FLT_MANT_DIG 24 /* p */ #define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */ #define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */

View File

@ -34,10 +34,14 @@
#ifndef _MACHINE_FLOAT_H_ #ifndef _MACHINE_FLOAT_H_
#define _MACHINE_FLOAT_H_ 1 #define _MACHINE_FLOAT_H_ 1
#include <sys/cdefs.h>
#define FLT_RADIX 2 /* b */ #define FLT_RADIX 2 /* b */
#define FLT_ROUNDS 1 /* FP addition rounds to nearest */ #define FLT_ROUNDS 1 /* FP addition rounds to nearest */
#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD 1 /* operands promoted to double */ #define FLT_EVAL_METHOD 1 /* operands promoted to double */
#define DECIMAL_DIG 35 /* max precision in decimal digits */ #define DECIMAL_DIG 35 /* max precision in decimal digits */
#endif
#define FLT_MANT_DIG 24 /* p */ #define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */ #define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */

View File

@ -46,8 +46,10 @@ __END_DECLS
#define FLT_RADIX 2 /* b */ #define FLT_RADIX 2 /* b */
#define FLT_ROUNDS __flt_rounds() #define FLT_ROUNDS __flt_rounds()
#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD 0 /* no promotion */ #define FLT_EVAL_METHOD 0 /* no promotion */
#define DECIMAL_DIG 35 /* max precision in decimal digits */ #define DECIMAL_DIG 35 /* max precision in decimal digits */
#endif
#define FLT_MANT_DIG 24 /* p */ #define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-7F /* b**(1-p) */ #define FLT_EPSILON 1.19209290E-7F /* b**(1-p) */