David James wrote:
[...] The previous compiler allowed one to write to a text file that had been opened with 'reset' and then 'extend'ed. GPC says:
./daj13: cannot write to read only file `daj13.pas' (error #422)
===== program daj13(input,output);
var f:text;
begin reset(f,'daj13.pas'); extend(f); writeln(f,'extra text'); end.
If you `close' the file before the `extend', it works.
Do you happen to know what Extended Pascal thinks about how `close' should work?
Peter