| I compared it with some textbook examples of
| "normal" stream writing. The "normal" get() method is illustrated in
| binary mode where "when the end of file is reached, the stream
| associated with the file becomes zero." This implies that the eof
| flag is set when the last byte is read. Any thoughts on the ability
| of get() to know when the __get_ptr == __get_end?
I believe you misinterpreted the phrase "when the end of file is reached,
the stream associated with the file becomes zero." When you read one byte at
a time, e.g., using get(), getting the last byte is like an elevator
reaching the bottom floor. It does not fail to proceed further unless you
try to go "down". Analogously, when you get() the last character of the file
/ stream, it is a valid character, and EOF indications are not set - what if
you were "throwing an exception" on EOF? You'd lose the last valid
character. Only when you try to read PAST the EOF is the flag set. This is
similar to requesting to read 5 bytes when reading a file in blocks, and
there are at least 5 bytes left before EOF.
--
HTH, Steve