[Python-Dev] Missing operator.call (original) (raw)
Greg Ewing greg.ewing at canterbury.ac.nz
Fri Feb 6 06:31:21 CET 2009
- Previous message: [Python-Dev] Missing operator.call
- Next message: [Python-Dev] Missing operator.call
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Guido van Rossum wrote:
What's so special about your proposal that requires a new keyword?
I was thinking about the proposals that are made from time to time for things like
yield *foo
to yield all the items from a sub-generator. I was also thinking about what could be done to make using generators as coroutines more convenient, and I came up with the idea of a new statement
call expr
which would be equivalent to
for x in expr: yield x
This happens to be the same as what "yield *" would do, so it kind of unifies the two issues.
-- Greg
- Previous message: [Python-Dev] Missing operator.call
- Next message: [Python-Dev] Missing operator.call
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]