aboutsummaryrefslogtreecommitdiffstats
path: root/java/incrementing-version-code
diff options
context:
space:
mode:
authorSpencer Baugh2025-02-16 20:16:19 -0500
committerStefan Monnier2025-03-21 17:06:19 -0400
commitb12a3a03ae134ab710170b43262fe8db13364727 (patch)
treefb81f656d8346b1f3455119a7bb4f72309e9a31a /java/incrementing-version-code
parentdf6669578001e49f44714301df71870654a2de33 (diff)
downloademacs-b12a3a03ae134ab710170b43262fe8db13364727.tar.gz
emacs-b12a3a03ae134ab710170b43262fe8db13364727.zip
Lazily highlight and insert candidates in *Completions*
From profiling, the main bottleneck in completion over large completion sets is display-completion-list, when there are many available candidates. For example, in my large monorepo, when completing over the 589196 files or the 73897 branches, even with the candidates narrowed down by typing some prefix to complete, TAB (when it shows *Completions*) or ? is slow, mostly in display-completion-list. However, rendering all the completion candidates is unnecessary if the *Completions* window is never scrolled to see those candiates. By eagerly inserting only some candidates and lazily highlighting and inserting the remaining candidates only when necessary, performance is much improved. * lisp/minibuffer.el (completion--insert-strings): Insert completions lazily. (bug#74561) (completions--lazy-insert-button): Add. (completion--insert-horizontal, completion--insert-one-column): Throw a continuation when enough lines of completions are inserted. (completion--insert-vertical): Add ignored lines argument. (minibuffer-completion-help): Set completion-lazy-hilit. (with-minibuffer-completions-window): Call completion--lazy-insert-strings. (with-minibuffer-completions-window): * lisp/simple.el (completion-setup-function): Preserve buffer-locals required for lazy completion insertion. (switch-to-completions): Call completion--lazy-insert-strings. * etc/NEWS: Announce.
Diffstat (limited to 'java/incrementing-version-code')
0 files changed, 0 insertions, 0 deletions