Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(196)

#15606: re.VERBOSE whitespace behavior not completely documented

Can't Edit
Can't Publish+Mail
Start Review
Created:
9 months, 2 weeks ago by stevencollins
Modified:
9 months, 2 weeks ago
Reviewers:
ezio.melotti
CC:
roysmith, ezio.melotti, mrabarnett, docs_python.org, storchaka, stevencollins_bluegoji.com
Visibility:
Public.

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats Patch
Doc/library/re.rst View 1 chunk +11 lines, -5 lines 2 comments Download

Messages

Total messages: 1
ezio.melotti
9 months, 2 weeks ago #1
http://bugs.python.org/review/15606/diff/5718/Doc/library/re.rst
File Doc/library/re.rst (right):

http://bugs.python.org/review/15606/diff/5718/Doc/library/re.rst#newcode540
Doc/library/re.rst:540: extension construct (so, for example, ``(?P<a_or_b> a |
b)`` is a
Reading this it seems to me that ``( ?:`` is allowed.  Maybe saying something
like "within tokens like ``(?:`` or ``(?P<...>``" is better.

http://bugs.python.org/review/15606/diff/5718/Doc/library/re.rst#newcode546
Doc/library/re.rst:546: the leftmost such ``'#'`` through the end of the line
are ignored.
I find this paragraph a bit confusing, and would rephrase it to something like:
"""
All the text after and including the ``'#'`` character is considered as comment
and ignored, unless the ``'#'`` is in a character class or it's preceded by an
unescaped backslash.
"""
Sign in to reply to this message.

RSS Feeds Recent Issues | This issue
This is Rietveld cbc36f91f3f7