open() description: Made it more clear that 'b' should always be

added to the mode value for binary files to improve
	portability.

Fixed latex2html weirdness with a couple of footnotes.
This commit is contained in:
Fred Drake 1999-04-05 21:22:41 +00:00
parent ae14230069
commit 9aa8543c84
1 changed files with 21 additions and 16 deletions

View File

@ -434,18 +434,23 @@ one argument, return the smallest of the arguments.
ignored). If the file cannot be opened, \exception{IOError} is
raised.
If \var{mode} is omitted, it defaults to \code{'r'}.
The optional \var{bufsize} argument specifies the file's desired
buffer size: 0 means unbuffered, 1 means line buffered, any other
positive value means use a buffer of (approximately) that size. A
negative \var{bufsize} means to use the system default, which is
usually line buffered for for tty devices and fully buffered for other
files. If omitted, the system default is used.%
\footnote{Specifying a buffer size currently has no effect on systems
that don't have \cfunction{setvbuf()}. The interface to specify the buffer
size is not done using a method that calls \cfunction{setvbuf()}, because
that may dump core when called after any I/O has been performed, and
there's no reliable way to determine whether this is the case.}
If \var{mode} is omitted, it defaults to \code{'r'}. When opening a
binary file, you should append \code{'b'} to the \var{mode} value
for improved portability. (It's useful even on systems which don't
treat binary and text files differently, where it serves as
documentation.) The optional \var{bufsize} argument specifies the
file's desired buffer size: 0 means unbuffered, 1 means line
buffered, any other positive value means use a buffer of
(approximately) that size. A negative \var{bufsize} means to use
the system default, which is usually line buffered for for tty
devices and fully buffered for other files. If omitted, the system
default is used.\footnote{
Specifying a buffer size currently has no effect on systems that
don't have \cfunction{setvbuf()}. The interface to specify the
buffer size is not done using a method that calls
\cfunction{setvbuf()}, because that may dump core when called
after any I/O has been performed, and there's no reliable way to
determine whether this is the case.}
\end{funcdesc}
\begin{funcdesc}{ord}{c}
@ -649,10 +654,10 @@ local symbol table. With a module, class or class instance object as
argument (or anything else that has a \member{__dict__} attribute),
returns a dictionary corresponding to the object's symbol table.
The returned dictionary should not be modified: the effects on the
corresponding symbol table are undefined.%
\footnote{In the current implementation, local variable bindings
cannot normally be affected this way, but variables retrieved from
other scopes (e.g. modules) can be. This may change.}
corresponding symbol table are undefined.\footnote{
In the current implementation, local variable bindings cannot
normally be affected this way, but variables retrieved from
other scopes (e.g. modules) can be. This may change.}
\end{funcdesc}
\begin{funcdesc}{xrange}{\optional{start,} stop\optional{, step}}