Kaydet (Commit) c3e950cb authored tarafından Georg Brandl's avatar Georg Brandl

Clarify how hook_compressed determines how to open a file.

üst c98eeede
......@@ -165,8 +165,9 @@ filtering is disabled when standard input is read.
The two following opening hooks are provided by this module:
\begin{funcdesc}{hook_compressed}{filename, mode}
Transparently opens files compressed with gzip and bzip2 using
the \module{gzip} and \module{bz2} modules.
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.
Usage example:
\samp{fi = fileinput.FileInput(openhook=fileinput.hook_compressed)}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment