summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew M. Kuchling <amk@amk.ca>2000-06-18 20:27:10 (GMT)
committerAndrew M. Kuchling <amk@amk.ca>2000-06-18 20:27:10 (GMT)
commite8d52af54bb90459d941ecdd683bc8416bc47b48 (patch)
treea8d60446bdf499c157d4110a708de0d3625d954f
parentea34a84e543ecf0a05ea34fe5b7d84cb1bcd437d (diff)
downloadcpython-e8d52af54bb90459d941ecdd683bc8416bc47b48.zip
cpython-e8d52af54bb90459d941ecdd683bc8416bc47b48.tar.gz
cpython-e8d52af54bb90459d941ecdd683bc8416bc47b48.tar.bz2
Fix bug when the replacement template is a callable object
-rw-r--r--Lib/sre.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/sre.py b/Lib/sre.py
index 455cd27..637b776 100644
--- a/Lib/sre.py
+++ b/Lib/sre.py
@@ -90,7 +90,7 @@ def _expand(match, template):
def _subn(pattern, template, string, count=0):
# internal: pattern.subn implementation hook
if callable(template):
- filter = callable
+ filter = template
else:
# FIXME: prepare template
def filter(match, template=template):