diff options
author | Neal Norwitz <nnorwitz@gmail.com> | 2006-02-19 19:18:18 (GMT) |
---|---|---|
committer | Neal Norwitz <nnorwitz@gmail.com> | 2006-02-19 19:18:18 (GMT) |
commit | 87f28752525a79d229ba90f4635629675d71de40 (patch) | |
tree | 726e463efd21b1b6912617c94f6449cb630d58ba /Doc | |
parent | 0090a4c10d698e273e278a0eec50448a1e958bae (diff) | |
download | cpython-87f28752525a79d229ba90f4635629675d71de40.zip cpython-87f28752525a79d229ba90f4635629675d71de40.tar.gz cpython-87f28752525a79d229ba90f4635629675d71de40.tar.bz2 |
Minor tweaks
Diffstat (limited to 'Doc')
-rw-r--r-- | Doc/lib/libfileinput.tex | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Doc/lib/libfileinput.tex b/Doc/lib/libfileinput.tex index b653429..1c7dd5b 100644 --- a/Doc/lib/libfileinput.tex +++ b/Doc/lib/libfileinput.tex @@ -76,6 +76,7 @@ The following functions use the global state created by Return the integer ``file descriptor'' for the current file. When no file is opened (before the first line and between files), returns \code{-1}. +\versionadded{2.5} \end{funcdesc} \begin{funcdesc}{lineno}{} @@ -167,7 +168,9 @@ The two following opening hooks are provided by this module: \begin{funcdesc}{hook_compressed}{filename, mode} Transparently opens files compressed with gzip and bzip2 (recognized by the extensions \code{'.gz'} and \code{'.bz2'}) using the \module{gzip} - and \module{bz2} modules as well as normal files. + and \module{bz2} modules. If the filename extension is not \code{'.gz'} + or \code{'.bz2'}, the file is openned normally (ie, + using \function{open()} without any decompression). Usage example: \samp{fi = fileinput.FileInput(openhook=fileinput.hook_compressed)} |