summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorFredrik Lundh <fredrik@pythonware.com>2000-10-03 16:29:23 (GMT)
committerFredrik Lundh <fredrik@pythonware.com>2000-10-03 16:29:23 (GMT)
commit65d4bc616aa94f391951e2b9c699765531a27e3f (patch)
tree3a13aeca6ceba2a816fc3efad17c7fceed76fa0f /Modules
parent84294487dfbe394812512debb85e4b682cec8e57 (diff)
downloadcpython-65d4bc616aa94f391951e2b9c699765531a27e3f.zip
cpython-65d4bc616aa94f391951e2b9c699765531a27e3f.tar.gz
cpython-65d4bc616aa94f391951e2b9c699765531a27e3f.tar.bz2
Fixed negative lookahead/lookbehind. Closes bug #115618.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/_sre.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/Modules/_sre.c b/Modules/_sre.c
index 2412d42..6cfc3e3 100644
--- a/Modules/_sre.c
+++ b/Modules/_sre.c
@@ -20,6 +20,7 @@
* 2000-09-02 fl return -1 instead of None for start/end/span
* 2000-09-20 fl added expand method
* 2000-09-21 fl don't use the buffer interface for unicode strings
+ * 2000-10-03 fl fixed assert_not primitive
*
* Copyright (c) 1997-2000 by Secret Labs AB. All rights reserved.
*
@@ -774,8 +775,6 @@ SRE_MATCH(SRE_STATE* state, SRE_CODE* pattern, int level)
i = SRE_MATCH(state, pattern + 2, level + 1);
if (i <= 0)
return i;
- if (pattern[1] > 0 && state->ptr != ptr)
- return SRE_ERROR_STATE;
pattern += pattern[0];
break;
@@ -791,8 +790,6 @@ SRE_MATCH(SRE_STATE* state, SRE_CODE* pattern, int level)
return i;
if (i)
return 0;
- if (pattern[1] > 0 && state->ptr != ptr)
- return SRE_ERROR_STATE;
pattern += pattern[0];
break;