Make the reverse tabulated list sort stable

* lisp/emacs-lisp/tabulated-list.el (tabulated-list--get-sorter):
Make the reverse sorting stable (bug#37174).

Copyright-paperwork-exempt: yes
This commit is contained in:
Johan Claesson 2019-09-21 00:06:58 +02:00 committed by Lars Ingebrigtsen
parent 280cf93f31
commit 7c3ef77ccb

View file

@ -373,7 +373,7 @@ column. Negate the predicate that would be returned if
(if (stringp b) b (car b)))))))
;; Reversed order.
(if (cdr tabulated-list-sort-key)
(lambda (a b) (not (funcall sorter a b)))
(lambda (a b) (funcall sorter b a))
sorter))))
(defsubst tabulated-list--col-local-max-widths (col)