[Python-Dev] Generator objects and list comprehensions?
Sven R. Kunze
srkunze at mail.de
Wed Jan 25 12:34:36 EST 2017
On 25.01.2017 07:28, Joe Jevnik wrote:
>
> That was a long way to explain what the problem was. I think that that
> solution is to stop using `yield` in comprehensions because it is
> confusing, or to make `yield` in a comprehension a syntax error.
>
Same here; mixing comprehensions and yield (from) can't be explained
easily. A SyntaxError would be most appropriate.
Regards,
Sven
More information about the Python-Dev
mailing list