Previous: 2.2.6.5. Subrange Types To the Table of Contents Next: 2.2.6.7. Pointer Types
2.2.6.5. Subrange Types Table of Contents 2.2.6.7. Pointer Types

- 2.2.6.6. -
Table of Contents
2. TMT Pascal Language Description
2.2. Pascal Language Structure
2.2.6. Types
2.2.6.6. Real Types


2.2.6.6. Real Types


Real data types contain integer values as well as a fractional portion. Also known as floating point numbers, each real type consists of a significant, the fractional part, and an exponent, which is a power of ten.

TMT Pascal follows the IEEE standard for floating point number representation. There are five real data types available under TMT Pascal: Real48, Real, Single, Double, and Extended.
TypeRangeFormat
Single1.5 x 10-45 .. 3.4 x 1038 6 to 7 significant digits,
32-bit
Real482.9 x 10-39 .. 1.7 x 1038 11 to 12 significant digits,
48-bit
Real2.9 x 10-39 .. 1.7 x 1038 11 to 12 significant digits,
48-bit
Double5.0 x 10-324 .. 1.7 x 10308 15 to 16 significant digits,
64-bit
Extended1.9 x 10-4951 .. 1.1 x 104932 19-20 significant digits,
80-bit
In order to maintain data type backward compatibility with Borland Pascal, the real type has been changed back to the 6 byte version. In version 4.x sizeof(real) was 8. The double data type is identical to what the real data type was in TMT Pascal version 4.x.

Real48 is maintained for backward compatibility with older versions of the compiler. Since its storage format is not native to the Intel CPU's, it results in slower performance than other floating-point types.


Previous: 2.2.6.5. Subrange Types To the Table of Contents Next: 2.2.6.7. Pointer Types
2.2.6.5. Subrange Types Table of Contents 2.2.6.7. Pointer Types

- 2.2.6.6. -