summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib
diff options
context:
space:
mode:
authorTerry Jan Reedy <tjreedy@udel.edu>2012-02-05 19:30:43 (GMT)
committerTerry Jan Reedy <tjreedy@udel.edu>2012-02-05 19:30:43 (GMT)
commitd76c1bf5999d670baa4dfcf58f7290f31007a85d (patch)
treeb597f84522be5e0e3155ccdbcf6eb6473ac3a3e8 /Lib/idlelib
parentd15c5a869dd64362941d127a7216495ead0802f7 (diff)
downloadcpython-d76c1bf5999d670baa4dfcf58f7290f31007a85d.zip
cpython-d76c1bf5999d670baa4dfcf58f7290f31007a85d.tar.gz
cpython-d76c1bf5999d670baa4dfcf58f7290f31007a85d.tar.bz2
#13933 refine patch using 'new' builtin
Diffstat (limited to 'Lib/idlelib')
-rw-r--r--Lib/idlelib/AutoComplete.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/Lib/idlelib/AutoComplete.py b/Lib/idlelib/AutoComplete.py
index 5190990..4e17325 100644
--- a/Lib/idlelib/AutoComplete.py
+++ b/Lib/idlelib/AutoComplete.py
@@ -190,8 +190,7 @@ class AutoComplete:
bigl = eval("dir()", namespace)
bigl.sort()
if "__all__" in bigl:
- smalll = list(eval("__all__", namespace))
- smalll.sort()
+ smalll = sorted(eval("__all__", namespace))
else:
smalll = [s for s in bigl if s[:1] != '_']
else:
@@ -200,8 +199,7 @@ class AutoComplete:
bigl = dir(entity)
bigl.sort()
if "__all__" in bigl:
- smalll = list(entity.__all__)
- smalll.sort()
+ smalll = sorted(entity.__all__)
else:
smalll = [s for s in bigl if s[:1] != '_']
except: