GNU bug report logs - #16744
24.3.50; REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'

Previous Next

Package: emacs;

Reported by: Drew Adams <drew.adams <at> oracle.com>

Date: Thu, 13 Feb 2014 19:33:01 UTC

Severity: minor

Found in version 24.3.50

Fixed in version 24.4

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 16744 in the body.
You can then email your comments to 16744 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#16744; Package emacs. (Thu, 13 Feb 2014 19:33:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Drew Adams <drew.adams <at> oracle.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 13 Feb 2014 19:33:01 GMT) Full text and rfc822 format available.

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

From: Drew Adams <drew.adams <at> oracle.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 24.3.50; REGRESSION: C-h v does not show doc for
 `ediff-highlight-all-diffs'
Date: Thu, 13 Feb 2014 11:31:58 -0800 (PST)
emacs -Q
M-x load-library ediff
C-h v ediff-highlight-all-diffs

No doc shown, just an empty "Documentation:".

This regression was introduced in Emacs 24.1.  No problem for releases
before that.



In GNU Emacs 24.3.50.1 (i686-pc-mingw32)
 of 2014-02-11 on ODIEONE
Bzr revision: 116410 lekktu <at> gmail.com-20140211204823-l9l2s6tktfitq266
Windowing system distributor `Microsoft Corp.', version 6.1.7601
Configured using:
 `configure --prefix=/c/Devel/emacs/binary --enable-checking=yes,glyphs
 'CFLAGS=-O0 -g3' LDFLAGS=-Lc:/Devel/emacs/lib
 CPPFLAGS=-Ic:/Devel/emacs/include'




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Thu, 13 Feb 2014 20:30:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Drew Adams <drew.adams <at> oracle.com>, Michael Kifer <kifer <at> cs.stonybrook.edu>
Cc: 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Thu, 13 Feb 2014 22:29:34 +0200
> Date: Thu, 13 Feb 2014 11:31:58 -0800 (PST)
> From: Drew Adams <drew.adams <at> oracle.com>
> 
> emacs -Q
> M-x load-library ediff
> C-h v ediff-highlight-all-diffs
> 
> No doc shown, just an empty "Documentation:".

That's because of the ediff-defvar-local macro:

  (defcustom ediff-highlight-all-diffs t
    "If nil, only the selected differences are highlighted.
  Otherwise, all difference regions are highlighted, but the selected region is
  shown in brighter colors."
    :type 'boolean
    :group 'ediff-highlighting)
  (ediff-defvar-local ediff-highlight-all-diffs t "")

It is invoked (here and elsewhere) with an empty string as the doc, so
that's what you get.

Michael, what's the purpose here?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Thu, 13 Feb 2014 21:02:01 GMT) Full text and rfc822 format available.

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

From: Drew Adams <drew.adams <at> oracle.com>
To: Eli Zaretskii <eliz <at> gnu.org>, Drew Adams <drew.adams <at> oracle.com>, Michael
 Kifer <kifer <at> cs.stonybrook.edu>
Cc: 16744 <at> debbugs.gnu.org
Subject: RE: bug#16744: 24.3.50;	REGRESSION: C-h v does not show doc for
 `ediff-highlight-all-diffs'
Date: Thu, 13 Feb 2014 13:01:16 -0800 (PST)
> That's because of the ediff-defvar-local macro:
> 
>   (defcustom ediff-highlight-all-diffs t
>     "If nil, only the selected differences are highlighted.
>   Otherwise, all difference regions are highlighted, but the
> selected region is
>   shown in brighter colors."
>     :type 'boolean
>     :group 'ediff-highlighting)
>   (ediff-defvar-local ediff-highlight-all-diffs t "")
> 
> It is invoked (here and elsewhere) with an empty string as the doc,
> so that's what you get.

I see.  Seems like such a macro, if really needed, should at least
reuse the main doc string, in _addition_ to adding any local-binding
doc string.  Or perhaps allow for either adding or replacing.
But it should not require duplicating the literal string as an
argument, just to provide doc for the local var.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 07:54:02 GMT) Full text and rfc822 format available.

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

From: Michael Kifer <michael.kifer <at> stonybrook.edu>
To: Eli Zaretskii <eliz <at> gnu.org>, Drew Adams <drew.adams <at> oracle.com>
Cc: "16744 <at> debbugs.gnu.org" <16744 <at> debbugs.gnu.org>
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 02:53:31 -0500
Strange. When I run it with .emacs, then

M-x describe-variable ediff-highlight-all-diffs

returns

Documentation:
If nil, only the selected differences are highlighted.
Otherwise, all difference regions are highlighted, but the selected 
region is
shown in brighter colors.

But if it is started with emacs -q then the documentation string is not 
shown.

--

       --- michael



On 02/13/2014 03:29 PM, Eli Zaretskii wrote:
>> Date: Thu, 13 Feb 2014 11:31:58 -0800 (PST)
>> From: Drew Adams <drew.adams <at> oracle.com>
>>
>> emacs -Q
>> M-x load-library ediff
>> C-h v ediff-highlight-all-diffs
>>
>> No doc shown, just an empty "Documentation:".
> That's because of the ediff-defvar-local macro:
>
>    (defcustom ediff-highlight-all-diffs t
>      "If nil, only the selected differences are highlighted.
>    Otherwise, all difference regions are highlighted, but the selected region is
>    shown in brighter colors."
>      :type 'boolean
>      :group 'ediff-highlighting)
>    (ediff-defvar-local ediff-highlight-all-diffs t "")
>
> It is invoked (here and elsewhere) with an empty string as the doc, so
> that's what you get.
>
> Michael, what's the purpose here?





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 09:23:01 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Michael Kifer <michael.kifer <at> stonybrook.edu>
Cc: drew.adams <at> oracle.com, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 11:22:32 +0200
> Date: Fri, 14 Feb 2014 02:53:31 -0500
> From: Michael Kifer <michael.kifer <at> stonybrook.edu>
> CC: "16744 <at> debbugs.gnu.org" <16744 <at> debbugs.gnu.org>
> 
> Strange. When I run it with .emacs, then
> 
> M-x describe-variable ediff-highlight-all-diffs
> 
> returns
> 
> Documentation:
> If nil, only the selected differences are highlighted.
> Otherwise, all difference regions are highlighted, but the selected 
> region is
> shown in brighter colors.
> 
> But if it is started with emacs -q then the documentation string is not 
> shown.

What is in your .emacs?

Anyway, can you explain why do we need _both_ defcustom and
ediff-defvar-local for the same variable?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 10:22:02 GMT) Full text and rfc822 format available.

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

From: Michael Kifer <michael.kifer <at> stonybrook.edu>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: drew.adams <at> oracle.com, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 05:20:54 -0500
[Message part 1 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 10:44:02 GMT) Full text and rfc822 format available.

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

From: Michael Kifer <michael.kifer <at> stonybrook.edu>
To: Eli Zaretskii <eliz <at> gnu.org>, Drew Adams <drew.adams <at> oracle.com>
Cc: "16744 <at> debbugs.gnu.org" <16744 <at> debbugs.gnu.org>
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 05:43:45 -0500
[Message part 1 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 11:15:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Michael Kifer <michael.kifer <at> stonybrook.edu>
Cc: drew.adams <at> oracle.com, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 13:14:05 +0200
> Date: Fri, 14 Feb 2014 05:43:45 -0500
> From: Michael Kifer <michael.kifer <at> stonybrook.edu>
> CC: "16744 <at> debbugs.gnu.org" <16744 <at> debbugs.gnu.org>
> 
>     This problem is caused by some change in the emacs compiler.
>     The reason I was not seeing it is because I was using .elc files of
>     my development copy of ediff, which were compiled with an older
>     version of emacs. With those .elc's the documentation string was
>     being shown.
> 
>     Perhaps the empty doc-string in defvar now zaps the doc-string
>     specified in the preceding defcustom while previously it didn't? If
>     so, the previous behavior was smarter.

But why do we need both the defcustom and the defvar in the macro?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 19:15:02 GMT) Full text and rfc822 format available.

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

From: Michael Kifer <michael.kifer <at> stonybrook.edu>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: drew.adams <at> oracle.com, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 14:14:22 -0500
[Message part 1 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 20:59:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Michael Kifer <michael.kifer <at> stonybrook.edu>
Cc: drew.adams <at> oracle.com, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 22:58:47 +0200
> Date: Fri, 14 Feb 2014 14:14:22 -0500
> From: Michael Kifer <michael.kifer <at> stonybrook.edu>
> CC: drew.adams <at> oracle.com, 16744 <at> debbugs.gnu.org
> 
> But why do we need both the defcustom and the defvar in the macro?
> 
>     First, this was written a few years before defcustom came about.
>     Second, I haven't followed things for a number of years.
>     Is it possible to define permanent local vars using defcustom now?

I don't know.  Anyone?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 21:09:02 GMT) Full text and rfc822 format available.

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

From: Glenn Morris <rgm <at> gnu.org>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: Michael Kifer <michael.kifer <at> stonybrook.edu>, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 16:08:22 -0500
Eli Zaretskii wrote:

>>     Is it possible to define permanent local vars using defcustom now?
>
> I don't know.  Anyone?

No. (Buffer-local defcustoms generally don't work very well.)
http://debbugs.gnu.org/cgi/bugreport.cgi?bug=14591




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 21:53:02 GMT) Full text and rfc822 format available.

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

From: Michael Kifer <michael.kifer <at> stonybrook.edu>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: drew.adams <at> oracle.com, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 16:52:25 -0500
[Message part 1 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 22:23:02 GMT) Full text and rfc822 format available.

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

From: Glenn Morris <rgm <at> gnu.org>
To: Michael Kifer <michael.kifer <at> stonybrook.edu>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 17:22:00 -0500
Michael Kifer wrote:

>  Short of fixing defcustom,

defcustom does not need fixing IMO.

> the right solution would be to tell defvar to not zap defcustom's
> doc-string with an empty string,

What?
Why not just don't use ediff-defvar-local with defcustoms?
Just write the two extra lines by hand?

AFAICS, it's precisely two variables that seem to be affected:
ediff-use-faces, ediff-highlight-all-diffs

So this email is longer than the change that will be needed.

>  as it was before the change.  Not sure when this change in behavior
>  of defvar happened, but probably within the last year or so.

Pretty sure it's this three-year old change:

http://debbugs.gnu.org/1821

rather than something to do with the byte-compiler or defcustom or whatever.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 22:36:02 GMT) Full text and rfc822 format available.

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

From: Michael Kifer <michael.kifer <at> stonybrook.edu>
To: Glenn Morris <rgm <at> gnu.org>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 17:35:26 -0500
[Message part 1 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Fri, 14 Feb 2014 23:25:02 GMT) Full text and rfc822 format available.

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

From: Michael Kifer <michael.kifer <at> stonybrook.edu>
To: Glenn Morris <rgm <at> gnu.org>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Fri, 14 Feb 2014 18:24:10 -0500
[Message part 1 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16744; Package emacs. (Sat, 15 Feb 2014 10:04:02 GMT) Full text and rfc822 format available.

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

From: Andreas Schwab <schwab <at> linux-m68k.org>
To: Michael Kifer <michael.kifer <at> stonybrook.edu>
Cc: 16744 <at> debbugs.gnu.org
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Sat, 15 Feb 2014 11:02:53 +0100
Michael Kifer <michael.kifer <at> stonybrook.edu> writes:

> <html style="direction: ltr;">

Please fix your mailer.

Andreas.

-- 
Andreas Schwab, schwab <at> linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."




Reply sent to Glenn Morris <rgm <at> gnu.org>:
You have taken responsibility. (Sun, 16 Feb 2014 03:35:02 GMT) Full text and rfc822 format available.

Notification sent to Drew Adams <drew.adams <at> oracle.com>:
bug acknowledged by developer. (Sun, 16 Feb 2014 03:35:04 GMT) Full text and rfc822 format available.

Message #55 received at 16744-done <at> debbugs.gnu.org (full text, mbox):

From: Glenn Morris <rgm <at> gnu.org>
To: 16744-done <at> debbugs.gnu.org
Cc: Michael Kifer <michael.kifer <at> stonybrook.edu>
Subject: Re: bug#16744: 24.3.50;
 REGRESSION: C-h v does not show doc for `ediff-highlight-all-diffs'
Date: Sat, 15 Feb 2014 22:34:29 -0500
Version: 24.4

Fixed.

http://lists.gnu.org/archive/html/emacs-diffs/2014-02/msg00221.html




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

This bug report was last modified 10 years and 51 days ago.

Previous Next


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