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

#27030: Remove deprecated re features

Can't Edit
Can't Publish+Mail
Start Review
Created:
3 years, 5 months ago by storchaka+cpython
Modified:
2 years, 10 months ago
Reviewers:
jimjjewett
CC:
barry, ned.deily, ezio.melotti, mrabarnett, r.david.murray, devnull_psf.upfronthosting.co.za, storchaka
Visibility:
Public.

Patch Set 1 #

Total comments: 5

Patch Set 2 #

Unified diffs Side-by-side diffs Delta from patch set Stats Patch
Doc/library/re.rst View 1 1 chunk +6 lines, -1 line 0 comments Download
Lib/sre_parse.py View 1 1 chunk +3 lines, -1 line 0 comments Download
Lib/test/test_re.py View 1 1 chunk +1 line, -1 line 0 comments Download
Misc/NEWS View 1 1 chunk +3 lines, -0 lines 0 comments Download

Messages

Total messages: 2
Jim.J.Jewett
http://bugs.python.org/review/27030/diff/17249/Doc/library/re.rst File Doc/library/re.rst (right): http://bugs.python.org/review/27030/diff/17249/Doc/library/re.rst#newcode443 Doc/library/re.rst:443: Unknown escape consist of ``'\'`` and ASCII letter now ...
3 years, 4 months ago #1
storchaka
3 years, 4 months ago #2
http://bugs.python.org/review/27030/diff/17249/Doc/library/re.rst
File Doc/library/re.rst (right):

http://bugs.python.org/review/27030/diff/17249/Doc/library/re.rst#newcode443
Doc/library/re.rst:443: Unknown escape consist of ``'\'`` and ASCII letter now
is error.
On 2016/05/23 15:56:30, Jim.J.Jewett wrote:
> consist => consisting.

Done.

> I think "escape" read better in the plural "escapes".
> What happens if you do it anyhow?  Does is raise a particular exception or
fail
> to compile and return None, or ...?

It fails to compile and raises the same exception as for other regular
expression errors.

http://bugs.python.org/review/27030/diff/17249/Lib/sre_parse.py
File Lib/sre_parse.py (right):

http://bugs.python.org/review/27030/diff/17249/Lib/sre_parse.py#newcode770
Lib/sre_parse.py:770: raise ValueError("cannot use LOCALE flag with a str
pattern")
On 2016/05/23 15:56:30, Jim.J.Jewett wrote:
> I suspect that people who get this error will still be struggling with the
> bytes/str split.  Perhaps:
> 
> "LOCALE flag is only valid for bytes patterns, not with str."
> 

This corresponds to the message "cannot use UNICODE flag with a bytes pattern".
Sign in to reply to this message.

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+