Skip to content

Commit b33d9e1

Browse files
Apply suggestion from @Dreamsorcerer
1 parent 03addd7 commit b33d9e1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Doc/library/zlib.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -311,8 +311,8 @@ Decompression objects support the following methods and attributes:
311311
For example, the full content could be read like::
312312

313313
process_output(d.decompress(data, max_length))
314-
while d.unconsumed_tail:
315-
process_output(d.decompress(d.unconsumed_tail, max_length))
314+
while chunk := d.decompress(d.unconsumed_tail, max_length):
315+
process_output(chunk)
316316

317317
.. versionchanged:: 3.6
318318
*max_length* can be used as a keyword argument.

0 commit comments

Comments
 (0)