Skip to content

Commit 8dce5ab

Browse files
committed
reset what the current doc was
1 parent 76f231a commit 8dce5ab

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

Lib/textwrap.py

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -415,14 +415,17 @@ def shorten(text, width, **kwargs):
415415
# -- Loosely related functionality -------------------------------------
416416

417417
def dedent(text):
418-
"""
419-
Remove any common leading whitespace from every line in text.
418+
"""Remove any common leading whitespace from every line in `text`.
420419
421-
Entirely blank lines are normalized to a newline character.
422-
Tabs and spaces are treated as distinct.
420+
This can be used to make triple-quoted strings line up with the left
421+
edge of the display, while still presenting them in the source code
422+
in indented form.
423423
424-
This implementation uses os.path.commonprefix (implemented in C)
425-
to compute the common margin of non-blank lines for maximal performance.
424+
Note that tabs and spaces are both treated as whitespace, but they
425+
are not equal: the lines " hello" and "\\thello" are
426+
considered to have no common leading whitespace.
427+
428+
Entirely blank lines are normalized to a newline character.
426429
"""
427430
# Fast paths for empty or simple text
428431
if not text:

0 commit comments

Comments
 (0)