This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Sergey.Kirpichev
Recipients Sergey.Kirpichev, benjamin.peterson, mark.dickinson, matrixise, paul.moore, r.david.murray, rhettinger, tim.peters
Date 2015-04-29.20:25:30
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
In-reply-to <>
On Wed, Apr 29, 2015 at 06:51:21PM +0000, Paul Moore wrote:
> But that's a sort without a key.

Why it does matter?  It have quick exit.  For same reasons - Python could...

> In Perl you do a key sort via:

That's just your implementation.  But we could add here a
quick exit as well.

> The fact of the matter is that what Python does is documented behaviour

No.  Unless you absolutely sure - all readers think that "sorting
process" starts even for trivial lists.  No reasons to believe in that
nonsense - as you could see from sorting implementations in other languages.

> benefit (small) isn't worth the cost of making a change (which would
> only be in Python 3.5 and later anyway

It's easy for users (i.e. me) to backport this feature (i.e. make wrapper for
sorted()).  Benefit is small, I admit, but why not remove unnecessary
restrictions from the language?  I hope, I did my best to explain why.
Date User Action Args
2015-04-29 20:25:30Sergey.Kirpichevsetrecipients: + Sergey.Kirpichev, tim.peters, rhettinger, paul.moore, mark.dickinson, benjamin.peterson, r.david.murray, matrixise
2015-04-29 20:25:30Sergey.Kirpichevlinkissue24075 messages
2015-04-29 20:25:30Sergey.Kirpichevcreate