Skip to content

Commit

Permalink
Fixed #2677 -- Removed the need to import sre and hence avoid a
Browse files Browse the repository at this point in the history
DeprecationWarning. Thanks, Tom Tobin.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@3814 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information
malcolmt committed Sep 24, 2006
1 parent 8f7ab8e commit b05e550
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions django/utils/simplejson/scanner.py
Expand Up @@ -3,12 +3,11 @@
""" """
import sre_parse, sre_compile, sre_constants import sre_parse, sre_compile, sre_constants
from sre_constants import BRANCH, SUBPATTERN from sre_constants import BRANCH, SUBPATTERN
from sre import VERBOSE, MULTILINE, DOTALL
import re import re


__all__ = ['Scanner', 'pattern'] __all__ = ['Scanner', 'pattern']


FLAGS = (VERBOSE | MULTILINE | DOTALL) FLAGS = (re.VERBOSE | re.MULTILINE | re.DOTALL)
class Scanner(object): class Scanner(object):
def __init__(self, lexicon, flags=FLAGS): def __init__(self, lexicon, flags=FLAGS):
self.actions = [None] self.actions = [None]
Expand Down

0 comments on commit b05e550

Please sign in to comment.