summaryrefslogtreecommitdiffstats
path: root/Doc/library
diff options
context:
space:
mode:
authorAndrew Svetlov <andrew.svetlov@gmail.com>2012-11-08 15:26:53 (GMT)
committerAndrew Svetlov <andrew.svetlov@gmail.com>2012-11-08 15:26:53 (GMT)
commit5c90436d6427981c52a181fd7c94d16fa1ce02cb (patch)
tree24ed1a8948367a7c6dacfb99efa13e3e2bec1f62 /Doc/library
parent0e9a0652759e59accf822f608997637e18450fd7 (diff)
downloadcpython-5c90436d6427981c52a181fd7c94d16fa1ce02cb.zip
cpython-5c90436d6427981c52a181fd7c94d16fa1ce02cb.tar.gz
cpython-5c90436d6427981c52a181fd7c94d16fa1ce02cb.tar.bz2
Issue #16439: Fix markup in example for stdtypes.
Thanks to Yongzhi Pan.
Diffstat (limited to 'Doc/library')
-rw-r--r--Doc/library/stdtypes.rst10
1 files changed, 5 insertions, 5 deletions
diff --git a/Doc/library/stdtypes.rst b/Doc/library/stdtypes.rst
index 6e6e8ce..1d7467d 100644
--- a/Doc/library/stdtypes.rst
+++ b/Doc/library/stdtypes.rst
@@ -1390,11 +1390,11 @@ functions based on regular expressions.
>>> import re
>>> def titlecase(s):
- return re.sub(r"[A-Za-z]+('[A-Za-z]+)?",
- lambda mo: mo.group(0)[0].upper() +
- mo.group(0)[1:].lower(),
- s)
-
+ ... return re.sub(r"[A-Za-z]+('[A-Za-z]+)?",
+ ... lambda mo: mo.group(0)[0].upper() +
+ ... mo.group(0)[1:].lower(),
+ ... s)
+ ...
>>> titlecase("they're bill's friends.")
"They're Bill's Friends."