GNU bug report logs - #22583
25.1.50; find-function-search-for-symbol don't call find-function-after-hook

Previous Next

Package: emacs;

Reported by: Tino Calancha <f92capac <at> gmail.com>

Date: Sun, 7 Feb 2016 15:16:01 UTC

Severity: minor

Tags: fixed, patch

Found in version 25.1.50

Fixed in version 26.1

Done: Lars Magne Ingebrigtsen <larsi <at> gnus.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 22583 in the body.
You can then email your comments to 22583 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#22583; Package emacs. (Sun, 07 Feb 2016 15:16:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Tino Calancha <f92capac <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sun, 07 Feb 2016 15:16:02 GMT) Full text and rfc822 format available.

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

From: Tino Calancha <f92capac <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 25.1.50; find-function-search-for-symbol don't call
 find-function-after-hook
Date: Mon, 8 Feb 2016 00:18:13 +0900 (JST)
[Message part 1 (text/plain, inline)]
Hi emacs,

when calling find-function or find-variable
find-function-after-hook is run.
In the ther hand, find-function-search-for-symbol
don't run this hook.

For example,
I set find-function-after-hook to always visit source code
in a read-only buffer. This work for find-function/variable.

But sometimes, you call describe-function/describe-variable,
and, after reading the doc. string you decide to take a look
in the implementation. In that cases the buffer may not be
in read-only mode because find-function-after-hook is not called.


In GNU Emacs 25.1.50.1 (x86_64-pc-linux-gnu, GTK+ Version 2.24.29)
Repository revision: 90c647b97f0e62ca8bc2fc1d27f0170136277fb7
[find-func.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#22583; Package emacs. (Mon, 08 Feb 2016 05:02:01 GMT) Full text and rfc822 format available.

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

From: Dmitry Gutov <dgutov <at> yandex.ru>
To: Tino Calancha <f92capac <at> gmail.com>, 22583 <at> debbugs.gnu.org
Subject: Re: bug#22583: 25.1.50; find-function-search-for-symbol don't call
 find-function-after-hook
Date: Mon, 8 Feb 2016 07:01:45 +0200
On 02/07/2016 05:18 PM, Tino Calancha wrote:

> when calling find-function or find-variable
> find-function-after-hook is run.
> In the ther hand, find-function-search-for-symbol
> don't run this hook.

find-function-search-for-symbol is a querying function. It can be used 
by different consumers, e.g. xref-location-marker. I'm not sure the user 
would want find-function-after-hook to run in every such case.

Maybe help-variable-def's button definition's help-function should run 
the hook explicitly instead.





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#22583; Package emacs. (Mon, 08 Feb 2016 12:47:01 GMT) Full text and rfc822 format available.

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

From: Tino Calancha <f92capac <at> gmail.com>
To: Dmitry Gutov <dgutov <at> yandex.ru>
Cc: Tino Calancha <f92capac <at> gmail.com>, 22583 <at> debbugs.gnu.org
Subject: Re: bug#22583: 25.1.50; find-function-search-for-symbol don't call
 find-function-after-hook
Date: Mon, 8 Feb 2016 21:50:04 +0900 (JST)
[Message part 1 (text/plain, inline)]
>find-function-search-for-symbol is a querying function. It can be used by different consumers, e.g. xref-location-marker.
>I'm not sure the user would want find-function-after-hook to run in every such case.
Right: the hook may be unnecessary called many times. Not good.

>Maybe help-variable-def's button definition's help-function should run the hook explicitly instead.
Thanks for the tip. This way looks more sensible.
[help-mode.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#22583; Package emacs. (Thu, 18 Feb 2016 00:50:01 GMT) Full text and rfc822 format available.

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

From: Tino Calancha <f92capac <at> gmail.com>
To: 22583 <at> debbugs.gnu.org
Subject: 25.1.50; find-library don't call find-function-after-hook
Date: Thu, 18 Feb 2016 09:52:54 +0900 (JST)
[Message part 1 (text/plain, inline)]
IMO, for consistency, find-function-after-hook should be
also run by find-library.
For instance, as mentioned above, i set this hook to always
open source code on read-only buffers.
If find-library don't run the hook, it may open a file in
writable mode.
[find-func.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#22583; Package emacs. (Sun, 21 Feb 2016 23:28:02 GMT) Full text and rfc822 format available.

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

From: Dmitry Gutov <dgutov <at> yandex.ru>
To: Tino Calancha <f92capac <at> gmail.com>, 22583 <at> debbugs.gnu.org,
 John Wiegley <jwiegley <at> gmail.com>
Subject: Re: bug#22583: 25.1.50; find-library don't call
 find-function-after-hook
Date: Mon, 22 Feb 2016 01:27:03 +0200
On 02/18/2016 02:52 AM, Tino Calancha wrote:
>
> IMO, for consistency, find-function-after-hook should be
> also run by find-library.
> For instance, as mentioned above, i set this hook to always
> open source code on read-only buffers.
> If find-library don't run the hook, it may open a file in
> writable mode.

Sounds good to me.

Tino, could you resend these as one patch, using 'git format-patch' as 
described in CONTRIBUTE, with an appropriate commit message (which means 
using ChangeLog-style description, as also described in CONTRIBUTE).

John, would you say it's okay for emacs-25?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#22583; Package emacs. (Mon, 22 Feb 2016 00:01:02 GMT) Full text and rfc822 format available.

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

From: John Wiegley <jwiegley <at> gmail.com>
To: Dmitry Gutov <dgutov <at> yandex.ru>
Cc: Tino Calancha <f92capac <at> gmail.com>, 22583 <at> debbugs.gnu.org
Subject: Re: bug#22583: 25.1.50;
 find-library don't call find-function-after-hook
Date: Sun, 21 Feb 2016 16:00:38 -0800
[Message part 1 (text/plain, inline)]
>>>>> Dmitry Gutov <dgutov <at> yandex.ru> writes:

> Tino, could you resend these as one patch, using 'git format-patch' as
> described in CONTRIBUTE, with an appropriate commit message (which means
> using ChangeLog-style description, as also described in CONTRIBUTE).

> John, would you say it's okay for emacs-25?

At this point, qualification for inclusion into emacs-25 is fairly strict (now
clarifying for the sake of future discussion):

  - It should *not* result in any changes to the NEWS file, APIs, or existing
    documentation. Not unless we missed something major.

  - If it fixes new behavior -- so, it hasn't been out in the wild yet -- then
    just fix it if you think it's not destabilizing.

  - If it corrects old behavior, sufficient testing is needed to ensure that
    this "right" behavior does not lead to surprising behavior after two
    pretests have already been out.

Be very cautious with changes at this point, since they won't have had the
benefit of those pretests. Especially if it's a breakage that has been broken
for a long time, I say it can stay broken until 25.2. But if we're smoothing
out new code before it hits the streets, there is still a little time for
that.

-- 
John Wiegley                  GPG fingerprint = 4710 CF98 AF9B 327B B80F
http://newartisans.com                          60E1 46C4 BD1A 7AC1 4BA2
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#22583; Package emacs. (Mon, 22 Feb 2016 00:06:01 GMT) Full text and rfc822 format available.

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

From: Dmitry Gutov <dgutov <at> yandex.ru>
To: John Wiegley <johnw <at> gnu.org>
Cc: Tino Calancha <f92capac <at> gmail.com>, 22583 <at> debbugs.gnu.org
Subject: Re: bug#22583: 25.1.50; find-library don't call
 find-function-after-hook
Date: Mon, 22 Feb 2016 02:04:54 +0200
On 02/22/2016 02:00 AM, John Wiegley wrote:

> At this point, qualification for inclusion into emacs-25 is fairly strict (now
> clarifying for the sake of future discussion):

Thanks, this is useful (especially the item 2), but could you also 
answer the question for this particular patch?

Like, I don't know if these changes should be reflected in the NEWS, or 
existing documentation.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#22583; Package emacs. (Mon, 22 Feb 2016 17:04:02 GMT) Full text and rfc822 format available.

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

From: John Wiegley <jwiegley <at> gmail.com>
To: Dmitry Gutov <dgutov <at> yandex.ru>
Cc: Tino Calancha <f92capac <at> gmail.com>, 22583 <at> debbugs.gnu.org
Subject: Re: bug#22583: 25.1.50;
 find-library don't call find-function-after-hook
Date: Mon, 22 Feb 2016 09:01:53 -0800
>>>>> Dmitry Gutov <dgutov <at> yandex.ru> writes:

> On 02/22/2016 02:00 AM, John Wiegley wrote:
>> At this point, qualification for inclusion into emacs-25 is fairly strict
>> (now clarifying for the sake of future discussion):

> Thanks, this is useful (especially the item 2), but could you also answer
> the question for this particular patch?

> Like, I don't know if these changes should be reflected in the NEWS, or
> existing documentation.

I'm not really sure about this particular change, not having followed the
whole thread.  Let me read it through today and get back to you.

-- 
John Wiegley                  GPG fingerprint = 4710 CF98 AF9B 327B B80F
http://newartisans.com                          60E1 46C4 BD1A 7AC1 4BA2




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#22583; Package emacs. (Mon, 22 Feb 2016 17:16:01 GMT) Full text and rfc822 format available.

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

From: Tino Calancha <f92capac <at> gmail.com>
To: 22583 <at> debbugs.gnu.org
Cc: Tino Calancha <f92capac <at> gmail.com>, John Wiegley <jwiegley <at> gmail.com>,
 Dmitry Gutov <dgutov <at> yandex.ru>
Subject: Re: bug#22583: 25.1.50; find-library don't call
 find-function-after-hook
Date: Tue, 23 Feb 2016 02:19:05 +0900 (JST)
[Message part 1 (text/plain, inline)]
> Tino, could you resend these as one patch, using 'git format-patch' as 
> described in CONTRIBUTE, with an appropriate commit message (which means 
> using ChangeLog-style description, as also described in CONTRIBUTE).
Attached the requested patch.
[0001-Run-find-function-after-hook-after-find-a-symbol.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#22583; Package emacs. (Mon, 25 Apr 2016 17:28:01 GMT) Full text and rfc822 format available.

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

From: Lars Magne Ingebrigtsen <larsi <at> gnus.org>
To: Tino Calancha <f92capac <at> gmail.com>
Cc: John Wiegley <jwiegley <at> gmail.com>, 22583 <at> debbugs.gnu.org,
 Dmitry Gutov <dgutov <at> yandex.ru>
Subject: Re: bug#22583: 25.1.50;
 find-library don't call find-function-after-hook
Date: Mon, 25 Apr 2016 19:27:22 +0200
Tino Calancha <f92capac <at> gmail.com> writes:

>> Tino, could you resend these as one patch, using 'git format-patch'
>> as described in CONTRIBUTE, with an appropriate commit message
>> (which means using ChangeLog-style description, as also described in
>> CONTRIBUTE).
> Attached the requested patch.

Thanks; applied to the trunk.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Added tag(s) fixed. Request was from Lars Magne Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Mon, 25 Apr 2016 17:28:02 GMT) Full text and rfc822 format available.

bug marked as fixed in version 25.2, send any further explanations to 22583 <at> debbugs.gnu.org and Tino Calancha <f92capac <at> gmail.com> Request was from Lars Magne Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Mon, 25 Apr 2016 17:28:02 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. (Tue, 24 May 2016 11:24:04 GMT) Full text and rfc822 format available.

bug unarchived. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Sun, 04 Dec 2016 02:50:09 GMT) Full text and rfc822 format available.

bug Marked as fixed in versions 26.1. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Sun, 04 Dec 2016 02:50:09 GMT) Full text and rfc822 format available.

bug No longer marked as fixed in versions 25.2. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Sun, 04 Dec 2016 02:50:09 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, 01 Jan 2017 12:24:24 GMT) Full text and rfc822 format available.

This bug report was last modified 8 years and 175 days ago.

Previous Next


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