diff options
Diffstat (limited to 'Lib/idlelib/ScriptBinding.py')
-rw-r--r-- | Lib/idlelib/ScriptBinding.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/idlelib/ScriptBinding.py b/Lib/idlelib/ScriptBinding.py index cc26510..c24bf81 100644 --- a/Lib/idlelib/ScriptBinding.py +++ b/Lib/idlelib/ScriptBinding.py @@ -65,10 +65,9 @@ class ScriptBinding: def tabnanny(self, filename): import tabnanny import tokenize - tabnanny.reset_globals() f = open(filename, 'r') try: - tokenize.tokenize(f.readline, tabnanny.tokeneater) + tabnanny.process_tokens(tokenize.generate_tokens(f.readline)) except tokenize.TokenError, msg: self.errorbox("Token error", "Token error:\n%s" % str(msg)) |