i have evidence and if you read the page i linked to youll see i am actually correct just outdated
You have no "evidence" and the page you linked to says no such thing. Even with the crappy definition given by thefreedictionary.com which can't seem to separate connotation from denotation, it is definitely an assertion you made.
Use a more reputable dictionary. Merriam Webster/Oxford/Cambridge...
Regardless of what you call it, just don't do it any more. =P
CP/M would not know that the file was 11 bytes long – it would only know it took up a single disk block, which would be a minimum of 128 bytes. As people generally like to know how big their files appear to be, rather than the number of blocks they take up, an end-of-file character was needed. CP/M re-used the Control-Z character (decimal code 26, hex 1A, original intended use lost in the mists of time) from the ASCII character set for this purpose – when a CP/M application read a Control-Z character it would typically treat that read as though an end-of-file had occurred.. There was nothing forcing applications to do this; apps that processed binary data would need some other means of knowing if they were at the end-of-file, and the OS itself did not treat Control-Z specially.
my books that got me into c and c++ programming also would say "until the EOF character has been reached.". i looked it up on merriam-webster and i guess that is an assertion, but im not going to apologize or stop, because i wasnt wrong. there was an eof character, just not anymore
It has never been right to assume in C++ that there is a character that signifies EOF which is stored in files. The eccentricities of CP/M have nothing to do with C++. The imprecision continues.
DTSCode wrote:
my books that got me into c and c++ programming also would say "until the EOF character has been reached."
There are plenty of bad books out there and plenty of folk who misread when they were beginners.
DTSCode wrote:
im not going to apologize or stop, because i wasnt wrong. there was an eof character, just not anymore
I don't need an apology, but you are wrong. Our discussion on C++ forums occurs in the context of C++, not a defunct operating system.
lets just drop it because
-neither of us are going to agree
-op's question has been answered
-i now know that on modern os's exact file length is known
-it would do no good to convince the other
Hey, one last note.
Want to know where else .eof() returns true and the read operation fails?
Currupted drive.
Usually happens on CD/DVD's, but also happens on old HDD/USB's.
And that's one MORE reason to loop on the operation itself.
If you want to discuss further, do, otherwise, don't.
I just wanted to point this out.