Date: Sun, 20 Sep 1998 10:16:54 +0300 (IDT) From: Eli Zaretskii To: Charles Marslett cc: djgpp-workers AT delorie DOT com Subject: Re: auto-binary-mode? [OT: What is text mode?] In-Reply-To: <3602AA07.DD74FEB0@vlsi.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk 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.