From: Lars Ingebrigtsen <larsi@gnus.org>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: master 760910f: Add a new buffer-local variable `minor-modes'
Date: Sun, 14 Feb 2021 19:40:41 +0100 [thread overview]
Message-ID: <87a6s6bihi.fsf@gnus.org> (raw)
In-Reply-To: <jwvim6u5xfe.fsf-monnier+emacs@gnu.org> (Stefan Monnier's message of "Sun, 14 Feb 2021 13:17:17 -0500")
Stefan Monnier <monnier@iro.umontreal.ca> writes:
>> Even if we had a function like that, looping over all possible minor
>> modes and calling predicates for them sounds hopelessly slow when you
>> have to do this for thousands of symbols...
>
> You could do it eagerly just once before calling all the predicate
> functions for all the commands, so that'd be cheap.
That's true, but it seems like an unnecessary complication.
For instance, the mode line contains `minor-mode-alist', and has to loop
through it to find the lighters to display. It could instead work off
of the `minor-mode' list, which is order(s) of magnitude shorter for most
people.
(And whatever mechanism we add for global modes. Just adding a
`global-minor-modes' variable is the obvious solution, but I was hoping
somebody had a non-obvious alternative.)
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
next prev parent reply other threads:[~2021-02-14 18:40 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20210214113754.21891.10736@vcs0.savannah.gnu.org>
[not found] ` <20210214113756.93760209D4@vcs0.savannah.gnu.org>
2021-02-14 12:26 ` master 760910f: Add a new buffer-local variable `minor-modes' Basil L. Contovounesios
2021-02-14 12:49 ` Lars Ingebrigtsen
2021-02-14 13:01 ` Lars Ingebrigtsen
2021-02-14 13:47 ` Lars Ingebrigtsen
2021-02-14 15:34 ` Stefan Monnier
2021-02-14 15:41 ` Lars Ingebrigtsen
2021-02-14 15:45 ` Lars Ingebrigtsen
2021-02-14 18:17 ` Stefan Monnier
2021-02-14 18:40 ` Lars Ingebrigtsen [this message]
2021-02-14 23:19 ` Stefan Monnier
2021-02-14 23:22 ` Lars Ingebrigtsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87a6s6bihi.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=emacs-devel@gnu.org \
--cc=monnier@iro.umontreal.ca \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).