Module Float
- Constant
DIGITS_10
 Constant MIN_10_EXP
 Constant MAX_10_EXP
 Constant MIN
 Constant MAX
 Constant EPSILON
 
- constantFloat.- DIGITS_10
 - constantFloat.- MIN_10_EXP
 - constantFloat.- MAX_10_EXP
 - constantFloat.- MIN
 - constantFloat.- MAX
 - constantFloat.- EPSILON
- Description
- These constants define the limits for floats on the current architecture: - DIGITS_10
- The number of decimal digits that can be represented. Any number with this many decimal digits can be stored in a float and converted back to decimal form without change. DIGITS_10 is not less than - 6.
- MIN_10_EXP
- MAX_10_EXP
- Limits of the exponent in decimal base. 10 raised to any number within this range can be represented in normalized form. MIN_10_EXP is not greater than - -37. MAX_10_EXP is not less than- 37.
- MIN
- The smallest normalized float greater than zero. It's not greater than - 1e-37.
- MAX
- The largest finite float. It's not less than - 1e37.
- EPSILON
- The difference between 1 and the smallest value greater than 1 that can be represented. It's not greater than - 1e-5.
 
- Note
- The size of the float type can be controlled when Pike is compiled with the configure flags - --with-double-precisionand- --with-long-double-precision. The default is to use the longest available float type that fits inside a pointer.
- Constant
FLOAT_PRECISION
 Constant DOUBLE_PRECISION
 Constant LONG_DOUBLE_PRECISION
 
- constantFloat.- FLOAT_PRECISION
 - constantFloat.- DOUBLE_PRECISION
 - constantFloat.- LONG_DOUBLE_PRECISION
- Description
- Tells which C compiler float type that is used for Pike floats. Only one of these constants will exist (with the value - 1) at runtime.- FLOAT_PRECISION
- The - floattype of the C compiler is used.
- DOUBLE_PRECISION
- The - doubletype of the C compiler is used.
- LONG_DOUBLE_PRECISION
- The - long doubletype of the C compiler is used.
 
- Note
- The float type can be controlled when Pike is compiled with the configure flags - --with-double-precisionand- --with-long-double-precision. The default is to use the longest available float type that fits inside a pointer.