According to The African Chief:
GPC doesn't like the spaces between e and +. Use
1.79e+308
instead of
1.79e + 308
You were right. How odd!
(I am not sure what the official Pascal standard says about this;
Me neither.
Me neither. It's impossible to understand them, as usual, but I have the impression that they do not want blanks in 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?
Peter
Dipl.-Phys. Peter Gerwinski, Essen, Germany, free physicist and programmer peter.gerwinski@uni-essen.de - http://home.pages.de/~peter.gerwinski/ [971005] maintainer GNU Pascal [971001] - http://home.pages.de/~gnu-pascal/ [971005]
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