all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#24676: 25.1; `completion-pcm-all-completions' should not reverse order of candidates
@ 2016-10-12 16:56 Drew Adams
  2016-10-17  8:19 ` Michael Heerdegen
  2016-10-17 16:29 ` Stefan Monnier
  0 siblings, 2 replies; 6+ messages in thread
From: Drew Adams @ 2016-10-12 16:56 UTC (permalink / raw)
  To: 24676

Because of this part, at the end of the function,
`completion-pcm-all-completions' reverses the order of the candidates.

(let ((poss ()))
  (dolist (c compl)
    (when (string-match-p regex c) (push c poss))) ; <==== reverses
  poss)

It should not do this.  Users should be able to depend on whatever order
the candidates are already in (as returned by `all-completions').

For example, for buffer candidates, the default order from
`all-completions' is last-display-time order.

The fix is trivial:

(let ((poss ()))
  (dolist (c compl)
    (when (string-match-p regex c) (push c poss)))
  (nreverse poss))


In GNU Emacs 25.1.1 (x86_64-w64-mingw32)
 of 2016-09-17
Windowing system distributor `Microsoft Corp.', version 6.1.7601
Configured using:
 `configure --without-dbus --without-compress-install CFLAGS=-static'





^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-10-18 14:22 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-12 16:56 bug#24676: 25.1; `completion-pcm-all-completions' should not reverse order of candidates Drew Adams
2016-10-17  8:19 ` Michael Heerdegen
2016-10-17 16:29 ` Stefan Monnier
2016-10-18  8:11   ` Michael Heerdegen
2016-10-18 13:56     ` Drew Adams
2016-10-18 14:22       ` Michael Heerdegen

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.