From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Stefan Kangas <stefan@marxist.se>
Cc: 53153@debbugs.gnu.org
Subject: bug#53153: package-quickstart: unusual autoload form in selectrum gives byte-compilation warning
Date: Thu, 13 Jan 2022 09:46:21 -0500 [thread overview]
Message-ID: <jwvilunvgq9.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <CADwFkm=FBeSJdNb9tj+Cnj8_4K+bjHJPBkx1fntTgCvF-d2e-g@mail.gmail.com> (Stefan Kangas's message of "Sun, 9 Jan 2022 22:46:59 -0600")
> This unusual arrangement means that we end up with this interesting form
> in package-quickstart.el (pretty-printed):
>
> (define-minor-mode selectrum-mode
> "Minor mode to use Selectrum for `completing-read'."
> :global t
> (if selectrum-mode (progn
[...]
Global minor modes define a `defcustom` and its :group is usually
provided by default by the last `defgroup` but if you copy this
`define-minor-mode` to some other file (such as an autoloads file), then
you can't rely on this defaulting so you should provide
a `:group` explicitly.
Regarding using such a "trick" or placing the minor mode in its own
file, both approaches have their advantages and disadvantages so while
it's unusual I don't see a problem with it.
Stefan
next prev parent reply other threads:[~2022-01-13 14:46 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-10 4:46 bug#53153: package-quickstart: unusual autoload form in selectrum gives byte-compilation warning Stefan Kangas
2022-01-13 9:11 ` Lars Ingebrigtsen
2022-01-13 11:20 ` Stefan Kangas
2022-01-13 14:46 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2022-01-13 15:30 ` Stefan Kangas
2022-01-13 16:20 ` bug#53153: [External] : " Drew Adams
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=jwvilunvgq9.fsf-monnier+emacs@gnu.org \
--to=bug-gnu-emacs@gnu.org \
--cc=53153@debbugs.gnu.org \
--cc=monnier@iro.umontreal.ca \
--cc=stefan@marxist.se \
/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).