GNU bug report logs - #18349
24.3.92; define-minor-mode: generated doc of hook: mode vs. modefun

Previous Next

Package: emacs;

Reported by: michael_heerdegen <at> web.de

Date: Thu, 28 Aug 2014 22:28:01 UTC

Severity: minor

Found in version 24.3.92

Fixed in version 25.1

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 18349 in the body.
You can then email your comments to 18349 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#18349; Package emacs. (Thu, 28 Aug 2014 22:28:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to michael_heerdegen <at> web.de:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 28 Aug 2014 22:28:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Michael Heerdegen <michael_heerdegen <at> web.de>
To: bug-gnu-emacs <at> gnu.org
Subject: 24.3.92; define-minor-mode: generated doc of hook: mode vs. modefun
Date: Fri, 29 Aug 2014 00:26:41 +0200
[Message part 1 (text/plain, inline)]
Hello,


in emacs -Q, eval

(define-minor-mode my-minor-mode
  "Doc"
  :variable foo
  ...)

Then, C-h v my-minor-mode-hook:

[...]
Documentation:
Hook run after entering or leaving `foo'.
[...]                              ^^^^^

This makes no sense, the doc of the hook should include the name of the
mode function, not that of the variable.

That happens e.g. for `read-only-mode-hook'.

Is this the right thing?

[easy-mmode.patch (text/x-diff, inline)]
*** /tmp/ediff9150_DV	2014-08-29 00:18:07.582868434 +0200
--- /home/micha/software/emacs/lisp/emacs-lisp/easy-mmode.el	2014-08-29 00:17:46.634718136 +0200
***************
*** 300,306 ****
           ,(format "Hook run after entering or leaving `%s'.
  No problems result if this variable is not bound.
  `add-hook' automatically binds it.  (This is true for all hook variables.)"
!                   mode))
  
         ;; Define the minor-mode keymap.
         ,(unless (symbolp keymap)	;nil is also a symbol.
--- 300,306 ----
           ,(format "Hook run after entering or leaving `%s'.
  No problems result if this variable is not bound.
  `add-hook' automatically binds it.  (This is true for all hook variables.)"
!                   modefun))
  
         ;; Define the minor-mode keymap.
         ,(unless (symbolp keymap)	;nil is also a symbol.
[Message part 3 (text/plain, inline)]

Thanks,

Michael.




In GNU Emacs 24.3.92.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.12.2)
 of 2014-08-11 on drachen
Windowing system distributor `The X.Org Foundation', version 11.0.11600000
System Description:	Debian GNU/Linux testing (jessie)

Important settings:
  value of $LC_ALL: de_DE.utf8
  value of $LC_COLLATE: C
  value of $LC_TIME: C
  value of $LANG: de_DE.utf8
  locale-coding-system: utf-8-unix


Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#18349; Package emacs. (Fri, 29 Aug 2014 02:02:02 GMT) Full text and rfc822 format available.

Message #8 received at 18349 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
To: Michael Heerdegen <michael_heerdegen <at> web.de>
Cc: 18349 <at> debbugs.gnu.org
Subject: Re: bug#18349: 24.3.92;
 define-minor-mode: generated doc of hook: mode vs. modefun
Date: Thu, 28 Aug 2014 22:01:29 -0400
> Is this the right thing?

Yes, it is.  Thanks for catching it, feel free to install,


        Stefan




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#18349; Package emacs. (Fri, 29 Aug 2014 20:40:03 GMT) Full text and rfc822 format available.

Message #11 received at 18349 <at> debbugs.gnu.org (full text, mbox):

From: Michael Heerdegen <michael_heerdegen <at> web.de>
To: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
Cc: 18349 <at> debbugs.gnu.org
Subject: Re: bug#18349: 24.3.92;
 define-minor-mode: generated doc of hook: mode vs. modefun
Date: Fri, 29 Aug 2014 22:39:01 +0200
Stefan Monnier <monnier <at> IRO.UMontreal.CA> writes:

> Yes, it is.  Thanks for catching it, feel free to install,

Installed in trunk in revision 117777.


Thanks,

Michael.




bug marked as fixed in version 24.5, send any further explanations to 18349 <at> debbugs.gnu.org and michael_heerdegen <at> web.de Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Fri, 29 Aug 2014 21:38:01 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 27 Sep 2014 11:24:03 GMT) Full text and rfc822 format available.

bug unarchived. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Sat, 04 Oct 2014 16:36:05 GMT) Full text and rfc822 format available.

bug Marked as fixed in versions 25.1. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Sat, 04 Oct 2014 16:36:05 GMT) Full text and rfc822 format available.

bug No longer marked as fixed in versions 24.5. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Sat, 04 Oct 2014 16:36:05 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sun, 02 Nov 2014 12:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 9 years and 198 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.