[Python-Dev] The `for y in [x]` idiom in comprehensions
Mike Miller
python-dev at mgmiller.net
Sat Feb 24 12:33:54 EST 2018
I'm not sure, I found the "with f(x) as y" form previously mentioned the most
readable despite it being a new use case, while not needing new keywords.
-Mike
On 2018-02-23 22:07, David Mertz wrote:
> FWIW, the nested loop over a single item is already in the language for 15 years
> or something. It's not that ugly, certainly not enough to need a new 'let' or
> 'where' keyword that basically does exactly the same thing with 3 fewer characters.
>
> On Feb 23, 2018 10:04 PM, David Mertz <mertz at gnosis.cx <mailto:mertz at gnosis.cx>>
> wrote:
More information about the Python-Dev
mailing list