[Python-checkins] cpython (2.7): #13933 refine patch using 'new' builtin
terry.reedy
python-checkins at python.org
Sun Feb 5 20:33:24 CET 2012
http://hg.python.org/cpython/rev/2b93ee675ec4
changeset: 74796:2b93ee675ec4
branch: 2.7
parent: 74783:ad20324229f4
user: Terry Jan Reedy <tjreedy at udel.edu>
date: Sun Feb 05 14:30:43 2012 -0500
summary:
#13933 refine patch using 'new' builtin
files:
Lib/idlelib/AutoComplete.py | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/Lib/idlelib/AutoComplete.py b/Lib/idlelib/AutoComplete.py
--- a/Lib/idlelib/AutoComplete.py
+++ b/Lib/idlelib/AutoComplete.py
@@ -190,8 +190,7 @@
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 @@
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:
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list