BFLOAT8 (eight-byte signed floating point)

Top  Previous  Next

 

label BFLOAT8([initial value]) [,DIM( )] [,OVER( )] [,NAME( )] [,EXTERNAL] [,DLL] [,STATIC]

 

[,THREAD] [,AUTO] [,PRIVATE] [,PROTECTED]

BFLOAT8

An eight-byte floating point number.

 

Format:     exponent    ±    significand

       | ........... | . | ..................... |

Bits:  63            55   54                      0

Range: 0, ± 5.877471754e-39 .. ± 1.7014118346e+38 (15 significant digits)

 

initial value

A numeric constant. If omitted, the initial value is zero, unless the AUTO attribute is present.

DIM

Dimension the variable as an array.

OVER

Share a memory location with another variable.

NAME

Specify an alternate, "external" name for the field.

EXTERNAL

Specify the variable is defined, and its memory is allocated, in an external library. Not valid within FILE, QUEUE, or GROUP declarations.

DLL

Specify the variable is defined in a .DLL. This is required in addition to the EXTERNAL attribute.

STATIC

Specify the variable's memory is permanently allocated.

THREAD

Specify memory for the variable is allocated once for each execution thread. Also implicitly adds the STATIC attribute on Procedure Local data.

AUTO

Specify the variable has no initial value.

PRIVATE

Specify the variable is not visible outside the module containing the CLASS methods. Valid only in a CLASS.

PROTECTED

Specify the variable is not visible outside base CLASS and derived CLASS methods. Valid only in a CLASS.

 

BFLOAT8 declares an eight-byte floating point signed numeric variable, using the Microsoft BASIC (double precision) format. This data type is normally used for compatibility with existing data since it is internally converted to a REAL before all arithmetic operations.

Example:

Count1 BFLOAT8                         !Declare eight-byte signed floating point

Count2 BFLOAT8,OVER(Count1)            !Declare OVER

Count3 BFLOAT8,DIM(4)                  !Declare it an array of 4 reals

Count4 BFLOAT8(5)                      !Declare with initial value

Count5 BFLOAT8,EXTERNAL                !Declare as external

Count6 BFLOAT8,EXTERNAL,DLL            !Declare as external in a .DLL

Count7 BFLOAT8,NAME('SixCount')        !Declare with external name

ExampleFile FILE,DRIVER('Btrieve')     !Declare a file

Record       RECORD

Count8        BFLOAT8,NAME('Counter')  !Declare with external name

            END

           END