[Python-checkins] r42733 - peps/trunk/pep-0343.txt peps/trunk/pep-0356.txt peps/trunk/pep-3000.txt
guido.van.rossum
python-checkins at python.org
Wed Mar 1 18:06:48 CET 2006
Author: guido.van.rossum
Date: Wed Mar 1 18:06:46 2006
New Revision: 42733
Modified:
peps/trunk/pep-0343.txt
peps/trunk/pep-0356.txt
peps/trunk/pep-3000.txt
Log:
343: fix bug in nested().
356: add some tentative future keywords.
3000: add some new ideas.
Modified: peps/trunk/pep-0343.txt
==============================================================================
--- peps/trunk/pep-0343.txt (original)
+++ peps/trunk/pep-0343.txt Wed Mar 1 18:06:46 2006
@@ -827,7 +827,6 @@
def nested(*contexts):
exits = []
vars = []
- exc = (None, None, None)
try:
try:
for context in contexts:
@@ -839,6 +838,8 @@
yield vars
except:
exc = sys.exc_info()
+ else:
+ exc = (None, None, None)
finally:
while exits:
exit = exits.pop()
@@ -846,6 +847,8 @@
exit(*exc)
except:
exc = sys.exc_info()
+ else:
+ exc = (None, None, None)
if exc != (None, None, None):
raise
Modified: peps/trunk/pep-0356.txt
==============================================================================
--- peps/trunk/pep-0356.txt (original)
+++ peps/trunk/pep-0356.txt Wed Mar 1 18:06:46 2006
@@ -75,6 +75,13 @@
Target for inclusion of each feature by March 16. At that point,
we should re-evaluate schedule or consider dropping feature.
+ Prepare for 'do' becoming a keyword in 2.6 (PEP 315)?
+ And as long as we're going wild, how about 'super'?
+ And what about 'interface' and 'implements'? (PEP 245)
+ Or 'switch' and 'case'? (PEP 275)
+
+ Add builtin @deprecated decorator?
+
PEP 352: Required Superclass for Exceptions
(Brett Cannon is expected to implement this.)
Modified: peps/trunk/pep-3000.txt
==============================================================================
--- peps/trunk/pep-3000.txt (original)
+++ peps/trunk/pep-3000.txt Wed Mar 1 18:06:46 2006
@@ -54,12 +54,17 @@
* ``exec`` as a statement is not worth it -- make it a function
* Add optional declarations for static typing [11]_
* Support only new-style classes; classic classes will be gone [1]_
+* Return iterators instead of lists where appropriate for atomic type methods
+ (e.g. ``dict.keys()``, ``dict.values()``, ``dict.items()``, etc.)
+ iter*() methods will be removed.
+* OR... Make keys() etc. return "views" a la Java collections???
* Replace ``print`` by a function [16]_
* Do something so you can catch multiple exceptions using ``except E1,
E2, E3:``. Maybe use ``except E1, E2, E3 as err:`` if you want the
error variable? [3]_
* ``None``, ``True`` and ``False`` become keywords [4]_
-* ``as`` becomes a keyword [5]_
+ (Or perhaps just ``None``?)
+* ``as`` becomes a keyword [5]_ (probably in 2.6 already)
* Have list comprehensions be syntactic sugar for passing an
equivalent generator expression to ``list()``; as a consequence the
loop variable will no longer be exposed [12]_
More information about the Python-checkins
mailing list