[Python-ideas] Fwd: Fwd: Fwd: unpacking generalisations for list comprehension

Sven R. Kunze srkunze at mail.de
Thu Oct 20 14:01:10 EDT 2016


On 18.10.2016 10:01, Daniel Moisset wrote:
> So, for me, this feature is something that could be covered with a 
> (new) function with no new syntax required. All you have to learn is 
> that instead of [*...] you use flatten(...)

The main motivation is not "hey we need yet another way for xyz" but 
"could we remove that inconsistency?". You wrote "[*...]"; which already 
works. It just that it does not work for all kinds of "..." . I hope 
that makes the motivation clearer.


I for one don't need yet another function or function cascade to make 
things work. "list(itertools.chain.from_iterable(...))" just works fine 
for all kinds of "...".


Cheers,
Sven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20161020/f89afb37/attachment.html>


More information about the Python-ideas mailing list