[Python-checkins] gh-102259: Fix re doc issue regarding right square brackets (GH-102264)

miss-islington webhook-mailer at python.org
Sat Feb 25 21:33:03 EST 2023


https://github.com/python/cpython/commit/972396143f9cb2478ab933a5ede39fa840d514bf
commit: 972396143f9cb2478ab933a5ede39fa840d514bf
branch: 3.10
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: miss-islington <31488909+miss-islington at users.noreply.github.com>
date: 2023-02-25T18:32:57-08:00
summary:

gh-102259: Fix re doc issue regarding right square brackets (GH-102264)


(cherry picked from commit bcadcde7122f6d3d08b35671d67e105149371a2f)

Co-authored-by: Skip Montanaro <skip.montanaro at gmail.com>
Co-authored-by: Terry Jan Reedy <tjreedy at udel.edu>

files:
M Doc/library/re.rst

diff --git a/Doc/library/re.rst b/Doc/library/re.rst
index 716d3401a2bb..1df9cbe5ea1c 100644
--- a/Doc/library/re.rst
+++ b/Doc/library/re.rst
@@ -232,7 +232,8 @@ The special characters are:
 
    * To match a literal ``']'`` inside a set, precede it with a backslash, or
      place it at the beginning of the set.  For example, both ``[()[\]{}]`` and
-     ``[]()[{}]`` will both match a parenthesis.
+     ``[]()[{}]`` will match a right bracket, as well as left bracket, braces,
+     and parentheses.
 
    .. .. index:: single: --; in regular expressions
    .. .. index:: single: &&; in regular expressions



More information about the Python-checkins mailing list