diff options
author | Ezio Melotti <ezio.melotti@gmail.com> | 2010-08-02 20:40:20 +0000 |
---|---|---|
committer | Ezio Melotti <ezio.melotti@gmail.com> | 2010-08-02 20:40:20 +0000 |
commit | 4c6daf10372af41d4b48dd1ac65d737c64c2d41c (patch) | |
tree | 1c09beb9cb50131295da68818734d18e39b1941d /Lib/idlelib/AutoComplete.py | |
parent | b55d36805566c092c11b8e38792c759742cd6a1f (diff) | |
download | cpython-git-4c6daf10372af41d4b48dd1ac65d737c64c2d41c.tar.gz |
Merged revisions 79576-79578 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r79576 | florent.xicluna | 2010-04-02 10:24:52 +0300 (Fri, 02 Apr 2010) | 2 lines
#7092: Fix additional "-3" warnings in the idlelib package, and convert to absolute imports.
........
r79577 | florent.xicluna | 2010-04-02 11:15:26 +0300 (Fri, 02 Apr 2010) | 2 lines
#7092: Drop the cmp argument.
........
r79578 | florent.xicluna | 2010-04-02 11:30:21 +0300 (Fri, 02 Apr 2010) | 2 lines
#7092: silence some py3k warnings
........
Diffstat (limited to 'Lib/idlelib/AutoComplete.py')
-rw-r--r-- | Lib/idlelib/AutoComplete.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/Lib/idlelib/AutoComplete.py b/Lib/idlelib/AutoComplete.py index d55b799256..fa1733f9a6 100644 --- a/Lib/idlelib/AutoComplete.py +++ b/Lib/idlelib/AutoComplete.py @@ -7,12 +7,7 @@ import os import sys import string -from configHandler import idleConf - -import AutoCompleteWindow -from HyperParser import HyperParser - -import __main__ +from idlelib.configHandler import idleConf # This string includes all chars that may be in a file name (without a path # separator) @@ -23,6 +18,11 @@ ID_CHARS = string.ascii_letters + string.digits + "_" # These constants represent the two different types of completions COMPLETE_ATTRIBUTES, COMPLETE_FILES = range(1, 2+1) +from idlelib import AutoCompleteWindow +from idlelib.HyperParser import HyperParser + +import __main__ + SEPS = os.sep if os.altsep: # e.g. '/' on Windows... SEPS += os.altsep @@ -193,7 +193,7 @@ class AutoComplete: smalll = eval("__all__", namespace) smalll.sort() else: - smalll = filter(lambda s: s[:1] != '_', bigl) + smalll = [s for s in bigl if s[:1] != '_'] else: try: entity = self.get_entity(what) @@ -203,7 +203,7 @@ class AutoComplete: smalll = entity.__all__ smalll.sort() else: - smalll = filter(lambda s: s[:1] != '_', bigl) + smalll = [s for s in bigl if s[:1] != '_'] except: return [], [] @@ -214,7 +214,7 @@ class AutoComplete: expandedpath = os.path.expanduser(what) bigl = os.listdir(expandedpath) bigl.sort() - smalll = filter(lambda s: s[:1] != '.', bigl) + smalll = [s for s in bigl if s[:1] != '.'] except OSError: return [], [] |