DSU pattern (was Re: Trouble sorting lists (unicode/locale re lated?))

SBrunning at trisystems.co.uk SBrunning at trisystems.co.uk
Mon Sep 22 10:22:39 EDT 2003


> From:	Peter Otten [SMTP:__peter__ at web.de]
> Everytime that someone posts a naive list.sort(compare), the DSU pattern
> is
> proposed to improve execution speed.
> 
> So maybe it's about time to change the sort() method to support a second
> argument
> 
> list.sort(compare=None, mapping=None)
> 
> that, if provided, would perform the DSU magic. Or was that already
> proposed
> and rejected?
 
Perhaps 'decorator' would be a better name than 'mapping'?

Cheers,
Simon Brunning,
http://www.brunningonline.net/simon/blog/
--LongSig





-----------------------------------------------------------------------
The information in this email is confidential and may be legally privileged.
It is intended solely for the addressee. Access to this email by anyone else
is unauthorised. If you are not the intended recipient, any disclosure,
copying, distribution, or any action taken or omitted to be taken in
reliance on it, is prohibited and may be unlawful. TriSystems Ltd. cannot
accept liability for statements made which are clearly the senders own.





More information about the Python-list mailing list