diff options
Diffstat (limited to 'Doc/library/bz2.rst')
-rw-r--r-- | Doc/library/bz2.rst | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Doc/library/bz2.rst b/Doc/library/bz2.rst index ae5a159..32df998 100644 --- a/Doc/library/bz2.rst +++ b/Doc/library/bz2.rst @@ -320,9 +320,11 @@ Writing and reading a bzip2-compressed file in binary mode: >>> with bz2.open("myfile.bz2", "wb") as f: ... # Write compressed data to file ... unused = f.write(data) + ... >>> with bz2.open("myfile.bz2", "rb") as f: ... # Decompress data from file ... content = f.read() + ... >>> content == data # Check equality to original object after round-trip True |