Mail Archives: djgpp-workers/1998/09/20/03:18:46
On Fri, 18 Sep 1998, Charles Marslett wrote:
> How does the "-literally" function work? No CR/LF -> LF conversions and
> binary-overwrite, I would guess. Any other specific behavior?
``Literally'' means literally: i.e., no conversions whatever. You get in
the buffer exactly what is on the disk. And vice versa, when you save
the buffer in the file.
> Maybe we are using different definitions of the phrase "side effect." To
> me, it refers to the fact that a programmer must have knowledge of the file
> system to properly write a program that does not manipulate the file system
> explicitly.
No, you just need to know what ANSI standard promises, and not use any
functionality beyond that, if you want your program to work on more than
a single platform. In the case of fseek/ftell, ANSI explicitly says that
you can't rely on any simple relationship between what fseek returns and
the byte offsets into the file.
- Raw text -