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/038956.html below:

copysort patch, was RE: [Python-Dev] inline sort option

copysort patch, was RE: [Python-Dev] inline sort option copysort patch, was RE: [Python-Dev] inline sort optionMark Russell mrussell at verio.net
Sat Oct 18 05:44:35 EDT 2003
On Sat, 2003-10-18 at 07:07, Brett C. wrote:
> I'm -1 as well.  Lists do not need to grow a method for something that 
> only replaces two lines of code that are not tricky in any form of the word.

And don't forget that the trivial function will sort any iterable, not
just lists.  I think

	for member in copysort(someset):

is better than

	for member in list(someset).copysort():

I'm against list.copysort(), and for either leaving things unchanged or
adding copysort() as a builtin (especially if it can use the reference
count trick to avoid unnecessary copies).

Mark Russell

	



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