var f : file of TYPE; ... get(f);
The "get" procedure reads the next data item from the file associated with "f" and stores the value in the buffer variable "f^". This file must be open before "get" is called.
If "eof(f)" is true at the time that "get" is called (i.e. you have already reached end of file), Pascal will issue an error message.
If you call "get" to read something and there is nothing left in the file, "get" will set "eof(f)" true and the contents of "f^" will be undefined. Subsequent calls to "get" will receive an error, as noted previously.
Copyright © 1996, Thinkage Ltd.