summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorNadeem Vawda <nadeem.vawda@gmail.com>2012-06-04 21:36:24 (GMT)
committerNadeem Vawda <nadeem.vawda@gmail.com>2012-06-04 21:36:24 (GMT)
commit6cbb20cdf61329ebfa6afcacad21ee6252fb5be5 (patch)
treea0493b69a4f5d2ac3cafa4e0b20efa5f3a856cef /Doc
parent33c34da5745f2e3fdc315e5098295621d8023674 (diff)
downloadcpython-6cbb20cdf61329ebfa6afcacad21ee6252fb5be5.zip
cpython-6cbb20cdf61329ebfa6afcacad21ee6252fb5be5.tar.gz
cpython-6cbb20cdf61329ebfa6afcacad21ee6252fb5be5.tar.bz2
Allow LZMAFile to accept modes with a "b" suffix.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/lzma.rst8
1 files changed, 5 insertions, 3 deletions
diff --git a/Doc/library/lzma.rst b/Doc/library/lzma.rst
index 156d77a..67e425d 100644
--- a/Doc/library/lzma.rst
+++ b/Doc/library/lzma.rst
@@ -40,9 +40,11 @@ Reading and writing compressed files
file will not be closed when the :class:`LZMAFile` is closed.
The *mode* argument can be either ``"r"`` for reading (default), ``"w"`` for
- overwriting, or ``"a"`` for appending. If *filename* is an existing file
- object, a mode of ``"w"`` does not truncate the file, and is instead
- equivalent to ``"a"``.
+ overwriting, or ``"a"`` for appending. These can equivalently be given as
+ ``"rb"``, ``"wb"``, and ``"ab"`` respectively.
+
+ If *filename* is a file object (rather than an actual file name), a mode of
+ ``"w"`` does not truncate the file, and is instead equivalent to ``"a"``.
When opening a file for reading, the input file may be the concatenation of
multiple separate compressed streams. These are transparently decoded as a