diff options
author | Just van Rossum <just@letterror.com> | 2003-07-02 21:37:16 +0000 |
---|---|---|
committer | Just van Rossum <just@letterror.com> | 2003-07-02 21:37:16 +0000 |
commit | 74902508dc395014dbdb9c2ed08263202e5d4e30 (patch) | |
tree | 81b32a9694015a6f76965a6c18b50aa37665c516 /Lib/sre.py | |
parent | 12723baceab61f8812d68575c962696cc4e77fa1 (diff) | |
download | cpython-git-74902508dc395014dbdb9c2ed08263202e5d4e30.tar.gz |
Addendum to #764548: restore 2.1 compatibility.
Diffstat (limited to 'Lib/sre.py')
-rw-r--r-- | Lib/sre.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/sre.py b/Lib/sre.py index 7910c83eac..ffe2bc36e6 100644 --- a/Lib/sre.py +++ b/Lib/sre.py @@ -221,7 +221,7 @@ def _compile(*key): pattern, flags = key if isinstance(pattern, _pattern_type): return pattern - if not isinstance(pattern, sre_compile.STRING_TYPES): + if not sre_compile.isstring(pattern): raise TypeError, "first argument must be string or compiled pattern" try: p = sre_compile.compile(pattern, flags) |