unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Eshel Yaron <me@eshelyaron.com>
Cc: Eli Zaretskii <eliz@gnu.org>, 74504@debbugs.gnu.org
Subject: bug#74504: 31.0.50; Wrong source directory in *Help*
Date: Fri, 13 Dec 2024 17:51:31 -0500	[thread overview]
Message-ID: <jwv5xnnp68m.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <m1frmyiq49.fsf@macbookpro.home> (Eshel Yaron's message of "Sun,  08 Dec 2024 08:35:34 +0100")

> I think that the workaround Stefan suggests makes sense.

Pushed a slightly tweaked patch to `master`.

> It doesn't make the code (and the implicit assumptions about when
> a file name is absolute and when it isn't) any clearer though.
> Another option may be something like the following, where we
> explicitly look only for .el files under load-path:

AFAICT the other parts of the code treat specially the C files rather
than the ELisp files.  Not sure if it matters (e.g. for `.so` Emacs
modules?), but I'd rather try and use the same hack here as elsewhere.

FWIW, the other place I find this distinction is
`find-function-search-for-symbol` where we do:

    (if (string-match "\\`src/\\(.*\\.\\(c\\|m\\)\\)\\'" library)
        (find-function-C-source symbol (match-string 1 library) type)

And the `src/*.c` strings come from `help-C-file-name`.

We should label those strings better in order to know more reliably
whether they're supposed to be searched in `load-path` or in
`find-function-S-source-directory` or god knows where else.

But in the mean time, this specific bug is fixed.


        Stefan






      reply	other threads:[~2024-12-13 22:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-24  7:12 bug#74504: 31.0.50; Wrong source directory in *Help* Eshel Yaron via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-25 23:26 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-12-07 12:26   ` Eli Zaretskii
2024-12-08  7:35     ` Eshel Yaron via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-12-13 22:51       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=jwv5xnnp68m.fsf-monnier+emacs@gnu.org \
    --to=bug-gnu-emacs@gnu.org \
    --cc=74504@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=me@eshelyaron.com \
    --cc=monnier@iro.umontreal.ca \
    /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 public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).