Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!iuvax!uxc!uxc.cso.uiuc.edu!ux1.cso.uiuc.edu!uxe.cso.uiuc.edu!hirchert From: hirchert@uxe.cso.uiuc.edu Newsgroups: comp.lang.fortran Subject: Re: Bogosity in Gould FORTRAN? Message-ID: <50500127@uxe.cso.uiuc.edu> Date: 4 May 89 16:11:00 GMT References: <7863@batcomputer.tn.cornell.edu> Lines: 23 Nf-ID: #R:batcomputer.tn.cornell.edu:7863:uxe.cso.uiuc.edu:50500127:000:1165 Nf-From: uxe.cso.uiuc.edu!hirchert May 4 11:11:00 1989 . Why the standard doesn't specify that files are read from the beginning. A number of systems support the concept of multi-file files (at least on tape) or other features in which system prepositioning is useful. It would be decidedly unfriendly to force the processor to blow that preprocessing away (especially for output files). [The Fortran 8x draft has a new OPEN option that allows you to specify whether you want to start at the beginning of the file, the end of the file, or where the system has left you positioned.] . A possible reason why Gould is opening files at the end. The original f77 compiler for Unix systems did this. It was done for a number of reasons. In particular, it provides a more convenient way to add to the end of a sequential file than having to read through the entire file. [Since Fortran 8x provides an explicit way to ask for positioning at the end of a file, we can hope that vendors will be smart enough to make the default system positioning be to the beginning of the file rather than the end.] Kurt W. Hirchert hirchert@ncsa.uiuc.edu National Center for Supercomputing Applications