all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "積丹尼 Dan Jacobson" <jidanni@jidanni.org>
To: 46839@debbugs.gnu.org
Subject: bug#46839: describe-variable should say something slightly different about invisibly defined variables
Date: Sun, 28 Feb 2021 23:41:23 +0800	[thread overview]
Message-ID: <87tupw6vz0.5.fsf@jidanni.org> (raw)

describe-variable says
  gnus-draft-setup-hook is a variable defined in ‘gnus-draft.el’.
  gnus-draft-mode-hook  is a variable defined in ‘gnus-draft.el’.

However one can be found in that file, one can't.

describe-variable could not be lying, therefore the one that can't be
found must still be declared, in some new invisible way. Fine.

However please make the help message output a little different,
so we will know if we are about to have a wild goose chase looking for
it or not.

"Well just click the link. If it is invisibly defined, you will just go
to the top of the file."

Yes, but still, please make the wording a little different:

E.g.,
  gnus-draft-setup-hook is a variable           defined in ‘gnus-draft.el’.
  gnus-draft-mode-hook  is a variable invisibly defined in ‘gnus-draft.el’.

(Proof:
$ zgrep gnus-draft-.*hook *.el.gz
gnus-draft.el.gz:(defcustom gnus-draft-setup-hook nil
gnus-draft.el.gz:    (run-hooks 'gnus-draft-setup-hook))))

OK. Now let's change some values and see what describe-variable says.

gnus-draft-mode-hook is a variable defined in ‘gnus-draft.el’.
Its value is ((lambda nil (goto-char (- (point-max) 1))))

gnus-draft-setup-hook is a variable defined in ‘gnus-draft.el’.
Its value is ((lambda nil (goto-char (- (point-max) 1))))
Original value was nil

gnus-summary-article-move-hook is a variable defined in ‘gnus-sum.el’.
Its value is nil

We can tell the second one, gnus-draft-setup-hook was chagnged by us,
because the Original value was mentioned.

But for the first and third, well one we tinkered with, and one we
didn't. But ah ha! There is no way to tell from the wording.

From the wording one guesses both still have the origninal value.

emacs-version "27.1"





             reply	other threads:[~2021-02-28 15:41 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-28 15:41 積丹尼 Dan Jacobson [this message]
2021-03-01 13:03 ` bug#46839: describe-variable should say something slightly different about invisibly defined variables 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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87tupw6vz0.5.fsf@jidanni.org \
    --to=jidanni@jidanni.org \
    --cc=46839@debbugs.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 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.