Bug in Pascal (Pix) on 4.2BSD
Ken Mandelberg
km at emory.UUCP
Sat Feb 4 10:06:55 AEST 1984
We have found an apparent bug in pix on 4.2 on real reads. The
same problem does not occur on either pc or pix on 4.1. Has
anyone fixed this yet? The bug report follows.
Ken Mandelberg
Dept of Math and CS
Emory University
{akgua,sb1,gatech}!emory!km
Subject: Pi gives error on real reads
Index: /usr/src/ucb/pascal/pi 4.2BSD
Description:
Pix blows up on the second real number read from stdin.
More precisely, the first real read following the read
of a real number entered with a decimal point will fail.
Repeat-By:
Script started on Fri Feb 3 18:36:32 1984
% cat test2.p
program cnvx(input,output);
var
x:real;
begin
readln(x); writeln(x);
readln(x); writeln(x);
end.
% pix test2.p
Execution begins...
1.1
1.10000000000000e+00
1.2
standard input: Bad data found on real read
Program error
Do you wish to enter the debugger? n
Error in "cnvx"+2 near line 7.
Execution terminated abnormally.
3 statements executed in 0000.80 seconds cpu time.
%
script done on Fri Feb 3 18:37:43 1984
Fix:
Unknown. Pc does not have the same bug, so it
can be used when real reads are needed.
More information about the Comp.unix.wizards
mailing list