[Python-checkins] peps: pep-0492: Incorporate some feedback from Stephen J. Turnbull.
yury.selivanov
python-checkins at python.org
Thu Apr 30 00:18:15 CEST 2015
https://hg.python.org/peps/rev/8472dc165730
changeset: 5808:8472dc165730
user: Yury Selivanov <yselivanov at sprymix.com>
date: Wed Apr 29 18:18:11 2015 -0400
summary:
pep-0492: Incorporate some feedback from Stephen J. Turnbull.
files:
pep-0492.txt | 19 +++++++++----------
1 files changed, 9 insertions(+), 10 deletions(-)
diff --git a/pep-0492.txt b/pep-0492.txt
--- a/pep-0492.txt
+++ b/pep-0492.txt
@@ -60,9 +60,11 @@
support in Python, it does not change the internal implementation of
coroutines, which are still based on generators.
-It is strongly suggested that the reader understands how coroutines are
-implemented in Python (PEP 342 and PEP 380). It is also recommended to
-read PEP 3156 (asyncio framework) and PEP 3152 (Cofunctions).
+This specification presumes knowledge of the implementation of
+coroutines in Python (PEP 342 and PEP 380). Motivation for the syntax
+changes proposed here comes from the asyncio framework (PEP 3156) and
+the "Cofunctions" proposal (PEP 3152, now rejected in favor of this
+specification).
From this point in this document we use the word *coroutine* to refer
to functions declared using the new syntax. *generator-based
@@ -1114,18 +1116,15 @@
Comprehensions
--------------
-For the sake of restricting the broadness of this PEP there is no new
-syntax for asynchronous comprehensions. This should be considered in a
-separate PEP, if there is a strong demand for this feature.
+Syntax for asynchronous comprehensions could be provided, but this
+construct is outside of the scope of this PEP.
Async lambdas
-------------
-Lambda coroutines are not part of this proposal. In this proposal they
-would look like ``async lambda(parameters): expression``. Unless there
-is a strong demand to have them as part of this proposal, it is
-recommended to consider them later in a separate PEP.
+Syntax for asynchronous lambda functions could be provided, but this
+construct is outside of the scope of this PEP.
Performance
--
Repository URL: https://hg.python.org/peps
More information about the Python-checkins
mailing list