From: Richard Stallman <rms@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: `define-minor-mode' makes erroneous docstrings.
Date: Tue, 12 Apr 2005 13:23:35 -0400 [thread overview]
Message-ID: <E1DLP6t-0007Eq-TQ@fencepost.gnu.org> (raw)
In-Reply-To: <200504120245.j3C2jWQ11924@raven.dms.auburn.edu> (message from Luc Teirlinck on Mon, 11 Apr 2005 21:45:32 -0500 (CDT))
The docstrings provided by `define-minor-mode' are wrong for many
minor-mode variables. They _automatically_ say that setting the
variable directly has no effect. I believe that this is wrong for the
majority of minor modes.
Would it work to try to distinguish by whether the "body" of
the define-minor-mode form is empty? If it is non-empty,
then it contains forms that will be executed by the function.
Just setting the variable won't execute those forms, which means
just setting the variable probably isn't right.
If the body is empty, then I think just setting the variable will
work.
As regards mode hooks, I agree it is a mistake to associate
mode hooks with the modes that, aside from their hooks, are
fully controlled by variables. Maybe this means we should
give define-minor-mode a new option to control whether to
make a hook.
next prev parent reply other threads:[~2005-04-12 17:23 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-04-12 2:45 `define-minor-mode' makes erroneous docstrings Luc Teirlinck
2005-04-12 3:09 ` Luc Teirlinck
2005-04-12 3:29 ` Luc Teirlinck
2005-04-12 3:57 ` Stefan Monnier
2005-04-12 17:04 ` Luc Teirlinck
2005-04-12 17:23 ` Richard Stallman [this message]
2005-04-13 2:33 ` Luc Teirlinck
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=E1DLP6t-0007Eq-TQ@fencepost.gnu.org \
--to=rms@gnu.org \
--cc=emacs-devel@gnu.org \
/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).