Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 6f4cf93

Browse filesBrowse files
committed
Improve formatting for sys.stdout
Suggested-by: @erlend-aasland
1 parent a9298cd commit 6f4cf93
Copy full SHA for 6f4cf93

File tree

Expand file treeCollapse file tree

1 file changed

+4
-4
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+4
-4
lines changed
Open diff view settings
Collapse file

‎Doc/library/pprint.rst‎

Copy file name to clipboardExpand all lines: Doc/library/pprint.rst
+4-4Lines changed: 4 additions & 4 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ Functions
5151
compact=False, sort_dicts=True, underscore_numbers=False)
5252

5353
Prints the formatted representation of *object* on *stream*, followed by a
54-
newline. If *stream* is ``None``, ``sys.stdout`` is used. This may be used
54+
newline. If *stream* is ``None``, :data:`sys.stdout` is used. This may be used
5555
in the interactive interpreter instead of the :func:`print` function for
5656
inspecting values (you can even reassign ``print = pprint.pprint`` for use
5757
within a scope).
@@ -136,9 +136,9 @@ This module defines one class:
136136
Construct a :class:`PrettyPrinter` instance. This constructor understands
137137
several keyword parameters.
138138

139-
*stream* (default ``sys.stdout``) is a :term:`file-like object` to
139+
*stream* (default :data:`sys.stdout`) is a :term:`file-like object` to
140140
which the output will be written by calling its :meth:`!write` method.
141-
If both *stream* and ``sys.stdout`` are ``None``, then
141+
If both *stream* and :data:`sys.stdout` are ``None``, then
142142
:meth:`~PrettyPrinter.pprint` silently returns.
143143

144144
Other values configure the manner in which nesting of complex data
@@ -179,7 +179,7 @@ This module defines one class:
179179
Added the *underscore_numbers* parameter.
180180

181181
.. versionchanged:: 3.11
182-
No longer attempts to write to ``sys.stdout`` if it is ``None``.
182+
No longer attempts to write to :data:`sys.stdout` if it is ``None``.
183183

184184
>>> import pprint
185185
>>> stuff = ['spam', 'eggs', 'lumberjack', 'knights', 'ni']

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.