GNU bug report logs -
#45443
28.0.50; Can't find definition of compilation--message->loc
Previous Next
Reported by: rms <at> gnu.org
Date: Sat, 26 Dec 2020 10:19:01 UTC
Severity: wishlist
Tags: fixed
Merged with 1457
Found in version 28.0.50
Fixed in version 28.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #16 received at 45443 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Drew Adams <drew.adams <at> oracle.com> writes:
>> It's a general problem with uses of cl-defstruct and similar
>> constructs: they generate functions and macros that the Help functions
>> are unable to find.
>
> Yep. It's a big doc/help problem, IMO. And
> we've moved more and more stuff to things like
> `cl-defstruct' (which in itself is fine).
>
> I don't see a good general solution to this
> problem. But it is, I think, something
> important for the quintessential
> "self-documenting" editor. I truly hope that
> some smart and ambitious hacker tackles this.
One possible approach is, if the regular expression code fails to find a
location, we can fall back to expand macros until we find the definition
(a defalias in the case of a function, or a defvar in the case of a
variable), or we reach the end of the file.
I attach a first implementation of this approach, with some tests for
the function definition that Richard wanted to find. I'm sure there are
still missing cases that are interesting (closures?). Give it a try and
see if there are still relevant symbols whose definition Emacs is unable
to locate. I'm also open to feedback about the macro expansion logic.
Could it be more efficient? Thanks.
[0001-Improve-find-definition-in-Help-buffers.patch (text/x-patch, attachment)]
This bug report was last modified 4 years and 140 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.