# Re: Is it time to legitimise REAL*8 etc?

*From*: glen herrmannsfeldt <gah@xxxxxxxxxxxxxxxx>*Date*: Sun, 20 Jul 2008 21:06:21 -0800

robin wrote:

Greg Lindahl wrote:

And this was a known flaw -- PL/1 suffered from it.

PL/I didn't not "suffer" from it.

PL/I provides a default precision (like REAL in Fortran)

with the use of the keyword FLOAT --

that gives what is generally known as single precision.

But that doesn't help for double precision. Also, FIXED

point would seem to have more problem with this. It is

find when you do know the needed precision, but namny times

you don't.

-- glen

When a declaration gives an actual precision, the hardware data type

actually used is one that exactly matches that precision, or (if there is

not one that exactly matches it) the minimum precision that exceeds that

precision is used, just as Fortran does.

In particular, if single-byte integers are requred, PL/I will give it.

If you want exactly 3-decimal digit computations, PL/I will give it.

In general, the precision can be given in terms of the number of

decimal digits desired for the calculation, e.g.,

declare x float decimal (10);

This has some convenient properties, in that when you print the

value of X using free-format, you get exactly 10 decimal digits printed.

.

**Follow-Ups**:**Re: Is it time to legitimise REAL*8 etc?***From:*robin

**References**:**Re: Is it time to legitimise REAL*8 etc?***From:*robin

- Prev by Date:
**Re: Anyone know about this error?** - Next by Date:
**Re: rpc's comments on Fortran 2008, part 3** - Previous by thread:
**Re: Is it time to legitimise REAL*8 etc?** - Next by thread:
**Re: Is it time to legitimise REAL*8 etc?** - Index(es):