mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
whatsnew: pprint's compact option.
This commit is contained in:
parent
dc9215f882
commit
63f4dd5e8f
1 changed files with 7 additions and 3 deletions
|
@ -1043,11 +1043,15 @@ Catucci in :issue:`4473`.)
|
||||||
pprint
|
pprint
|
||||||
------
|
------
|
||||||
|
|
||||||
The :mod:`pprint` module now supports *compact* mode for formatting long
|
The :mod:`pprint` module's :class:`~pprint.PrettyPrinter` class and its
|
||||||
sequences (:issue:`19132`).
|
:func:`~pprint.pformat`, and :func:`~pprint.pprint` functions have a new
|
||||||
|
option, *compact*, that controls how the output is formatted. Currently
|
||||||
|
setting *compact* to ``True`` means that sequences will be printed with as many
|
||||||
|
sequence elements as will fit within *width* on each (indented) line.
|
||||||
|
(Contributed by Serhiy Storchaka in :issue:`19132`.)
|
||||||
|
|
||||||
Long strings are now wrapped using Python's normal line continuation
|
Long strings are now wrapped using Python's normal line continuation
|
||||||
syntax (Contributed by Antoine Pitrou in :issue:`17150`.)
|
syntax. (Contributed by Antoine Pitrou in :issue:`17150`).
|
||||||
|
|
||||||
|
|
||||||
pty
|
pty
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue