From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Sat, 13 Jul 2019 08:42:25 +0000 (-0700) Subject: Fix typo in re.escape documentation (GH-14722) X-Git-Tag: v3.8.0b3~65 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=25d371ab74b9413231b2e8ea47be0fa49a04136d;p=thirdparty%2FPython%2Fcpython.git Fix typo in re.escape documentation (GH-14722) (cherry picked from commit fb6c1f8d3b116c7e3e3f814bf750d984a2f2ecbf) Co-authored-by: Robert DiPietro --- diff --git a/Doc/library/re.rst b/Doc/library/re.rst index 5ef72b535ce8..158248c3d147 100644 --- a/Doc/library/re.rst +++ b/Doc/library/re.rst @@ -942,7 +942,7 @@ form. >>> print('|'.join(map(re.escape, sorted(operators, reverse=True)))) /|\-|\+|\*\*|\* - This functions must not be used for the replacement string in :func:`sub` + This function must not be used for the replacement string in :func:`sub` and :func:`subn`, only backslashes should be escaped. For example:: >>> digits_re = r'\d+'