G <gp...@protonmail.com> added the comment:

I opened a relevant PR, https://github.com/python/cpython/pull/11781.

I believe a key parameter is inferior to a comparison callback. The former is a 
specific case of the latter, and in my use case would force me to create 
another class to serve as a comparator for my objects, at which point I might 
as well wrap them and add __lt__.

Furthermore, I believe this is more in-line with similar standard functions in 
other languages such as C++ (std::sort), Java (PriorityQueue) or Rust 
(slice.sort_by).

----------
nosy: +gpery

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue4356>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to