floating point constants_(re)
Wed, 22 Oct 1997 18:36:35 +0100 (MET)
>numbers. PEP does not accept it, so at least the standard
>does not requiire it.
>
>> > Borland Pascal accepts the spaces).
>>
>> Then perhaps GPC also should ?
>
>I don't think so since I consider this a bug in BP, not a feature.
>
>Other opinions?
>
I do *not* think that GPC should support this feature (rather: bug). The
only place where it could work (at all) is numerical constants in the
program, like the
const x = 1.0 e 3;
It cannot work in READ/READLN, because READ would have no way of knowing
whether the user entered 1.0 or 1000.0 (Borland Pascal returns 1.0).
Moreover, the statement
y := 2.0 e 4 * x;
(where x and y are reals) does not work in Borland Pascal, either. In short,
adding this feature would cause a lot of confusion to GPC users, IMHO.
So, unless we want to advertise that "... GPC supports all features and
*bugs* in Borland Pascal", I would vote against it.
Jesper Lund
Jesper Lund (jel@hha.dk)
HTML conversion by Lluís de Yzaguirre i Maura
Institut de Lingüística Aplicada -
Universitat "Pompeu Fabra"
e-mail: de_yza@upf.es