A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2003-October/038662.html below:

[Python-Dev] decorate-sort-undecorate

[Python-Dev] decorate-sort-undecorate [Python-Dev] decorate-sort-undecorateGuido van Rossum guido at python.org
Mon Oct 13 18:07:48 EDT 2003
> I've seen proposals for an extension to list comprehension, which would 
> be quite nice:
> 
>    [s for s in lst sortby s.lower()]
> 
> It reads nicely, and avoids lambdas and tiny helper functions.  Also 
> handles the sort-returns-None criticism.  But it adds syntax.  And 
> since it's not an in-place sort it won't perform as well (but probably 
> better than the decorator idiom anyway...?)

This has a very low probability to be accepted.  It suffers IMO from
the "SQL syndrome": having reserved words to the language that are
only meaningful in a very specific syntax yet are reserved
everywhere.  Until we have a general way to avoid that, I'd rather
not go that route.

--Guido van Rossum (home page: http://www.python.org/~guido/)

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4