Article View: gnu.g++.help
Article #913Streams and eof()
From: Axel Thimm
Date: Fri, 01 Mar 1996 20:43
Date: Fri, 01 Mar 1996 20:43
21 lines
1302 bytes
1302 bytes
Hello, I have had a look in the April draft, but I think that there is a small ambiguity about eof() methods in streams. Is the eof-flag raised, when the end of the stream is reached, or when an attempt to move past this end is made? I think the most common practice is the latter, but the ANSI draft uses the former statement. Declaring the end of a stream as the first charachter _after_ the last character of the stream would rescue the expression, but wouldn't fit into a concept of an end. (Usually one thinks of an end as belonging to the whole) As I am rather convinced, that the eof is raised at an attempt to meove past the end, I'd like to ask how to check this in a binary file without having to perform a movement. Regards, Axel. === Axel Thimm <axl@zedat.fu-berlin.de> Freie Universitaet Berlin ===
Technical Details
Message-ID:
<4h7ni1$bi9@fu-berlin.de>Path:
arc1-ca.pugleaf.net!axl.dialup.fu-berlin.DE!not-for-mailShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!axl.dialup.fu-berlin.DE!not-for-mail From: axl@zedat.fu-berlin.de (Axel Thimm) Newsgroups: gnu.g++.help,comp.lang.c++ Subject: Streams and eof() Date: Fri, 01 Mar 1996 20:43:31 GMT Organization: FU Berlin, Fachbereich Physik, Institut fuer Theoretische Physik Message-ID: <4h7ni1$bi9@fu-berlin.de> Reply-To: axl@zedat.fu-berlin.de NNTP-Posting-Host: axl.dialup.fu-berlin.de (160.45.218.93) X-Access: 16 17 19 X-Newsreader: Forte Free Agent 1.0.82