Commit Graph

79 Commits

Author SHA1 Message Date
Serhiy Storchaka
a61bfdbecd Issue #26475: Fixed debugging output for regular expressions with the (?x) flag. 2016-03-06 09:15:47 +02:00
Serhiy Storchaka
4809d1fccd Issues #814253, #9179: Warnings now are raised when group references and
conditional group references are used in lookbehind assertions in regular
expressions.
2015-02-21 12:08:36 +02:00
Benjamin Peterson
f8c8d2e366 backout fac649bf2d10 (#9179) for further consideration 2014-11-30 11:47:54 -05:00
Serhiy Storchaka
15ea870e29 Issues #814253, #9179: Group references and conditional group references now
work in lookbehind assertions in regular expressions.
2014-11-07 21:43:45 +02:00
Serhiy Storchaka
c0799e3a26 Issue #22423: Fixed debugging output of the GROUPREF_EXISTS opcode in the re
module.
2014-09-21 22:47:30 +03:00
Raymond Hettinger
008651c56e Display the name not the group itself 2014-06-22 19:45:07 -07:00
Raymond Hettinger
f595a127b8 Issue #8343: Named group error msgs did not show the group name. 2014-06-22 19:33:19 -07:00
Serhiy Storchaka
60bf0e4daa Issue #18050: Fixed an incompatibility of the re module with Python 2.7.3
and older binaries.
2013-09-20 21:25:53 +03:00
Serhiy Storchaka
34ecb118f1 Issue #18647: Correctly bound calculated min/max width of a subexpression.
Now max width is MAXREPEAT on 32- and 64-bit platforms when one of
subexpressions is unbounded repetition.
2013-08-19 22:53:46 +03:00
R David Murray
6077339270 #17341: Include name in re error message about invalid group name.
Patch by Jason Michalski.
2013-04-14 13:08:50 -04:00
Serhiy Storchaka
e18e05cce9 Issue #13169: The maximal repetition number in a regular expression has been
increased from 65534 to 2147483647 (on 32-bit platform) or 4294967294 (on
64-bit).
2013-02-16 16:47:15 +02:00
Ezio Melotti
5c4e32b131 #13899: \A, \Z, and \B now correctly match the A, Z, and B literals when used inside character classes (e.g. [A]). Patch by Matthew Barnett. 2013-01-11 08:32:01 +02:00
Ezio Melotti
ef3173877c #12759: sre_parse now raises a proper error when the name of the group is missing. Initial patch by Serhiy Storchaka. 2012-11-03 20:31:12 +02:00
Benjamin Peterson
32e7aa6ab9 remove set compat cruft 2008-10-14 22:37:18 +00:00
Benjamin Peterson
838c7b3619 remove some __getslice__ 2008-05-27 01:18:39 +00:00
Thomas Wouters
e3a985fe9a Make sre's SubPattern objects accept slice objects like it already accepts
simple slices.
2006-12-19 08:17:50 +00:00
Gustavo Niemeyer
6fa0c5a452 Bug #1202493: Fixing SRE parser to handle '{}' as perl does, rather than
considering it exactly like a '*'.
2005-09-14 08:54:39 +00:00
Raymond Hettinger
049ade2997 Complete the previous effort to factor out constant expressions
and improve the speed of the if/elif/else blocks.
2005-02-28 19:27:52 +00:00
Gustavo Niemeyer
f5a1599ebe Minor aesthetic change in sre_parse.py, as suggested by Mike Coleman. 2004-09-03 20:15:56 +00:00
Gustavo Niemeyer
a01a2ee933 Applying modified version of patch #1018386, which fixes
some escaping bugs in SRE.
2004-09-03 17:06:10 +00:00
Barry Warsaw
8bee76106e PEP 292 classes Template and SafeTemplate are added to the string module.
This patch includes test cases and documentation updates, as well as NEWS file
updates.

This patch also updates the sre modules so that they don't import the string
module, breaking direct circular imports.
2004-08-25 02:22:30 +00:00
Raymond Hettinger
968c56a626 Simple Optimizations:
* Factor constant expressions out of loops.
* Presize a list being grown to a known length.
2004-03-26 23:24:00 +00:00
Tim Peters
58eb11cf62 Whitespace normalization. 2004-01-18 20:29:55 +00:00
Gustavo Niemeyer
ad3fc44ccb Implemented non-recursive SRE matching. 2003-10-17 22:13:16 +00:00
Martin v. Löwis
53d93adc46 Patch #681152: Support escaped Unicode characters in classes. Fixes #612074.
Will backport to 2.2.
2003-04-19 08:37:24 +00:00