unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Štěpán Němec" <stepnem@gmail.com>
To: Stefan Monnier <monnier@IRO.UMontreal.CA>
Cc: 6716@debbugs.gnu.org
Subject: bug#6716: 23.2; Setting `find-function-source-path' has no effect.
Date: Tue, 27 Jul 2010 12:07:45 +0200	[thread overview]
Message-ID: <87aapddyq6.fsf@gmail.com> (raw)
In-Reply-To: <jwv39v6ncxp.fsf-monnier+emacs@gnu.org> (Stefan Monnier's message of "Mon, 26 Jul 2010 23:44:20 +0200")

Stefan Monnier <monnier@IRO.UMontreal.CA> writes:

>>> There lies the problem.  Other people do.  So the fix to your problem
>>> will need to satisfy both cases.
>> But if you care about that, you don't need `find-function-source-path'
>> at all, no?
>
> But your patch also affects the case where find-function-source-path is nil.

Yes. (And the current code ignores it even when it is non-nil. Actually,
the current code ignores everything -- it simply tries the one single
file name it guesses is right and either finds it or errors out.)

>> (And actually, I don't see a reliable way to jump to the
>> "right" source of a byte-compiled function in general (as I already
>> pointed out in the previous mail).)
>
> It doesn't have to work right when it's not possible.  But in the normal
> case where the .el and the .elc files are in the same directory and the
> .elc is the byte-compiled version of the .el file, it should work right.
>
>> Also, you replied to none of my other questions, notably -- do you
>> really (_really_) plan to reimplement `load-history', or was that just a
>> "would be nice to have"?
>
> I didn't say "reimplement".  Just that it needs to be tweaked with more
> info.  We've changed it several times in the past, there's nothing
> particularly tricky about that.
>
>> If the latter, could you propose a better solution that would improve
>> the current situation? (I'm sorry, but as I also already wrote,
>> I didn't really understand the point(s) you were making.)
>
> Some directories are not in the load-path, because the files therein are
> expected to be loaded via something like (require 'semantic/sort) or
> (load "term/vt100"), so if you see /blib/blob/semantic/sort.elc in the
> load-history, you can't just take "sort.elc" and look for "sort.el" on
> load-path because you'll find a completely unrelated file.

OK, I think I get it, thank you very much for the explanation. Honestly,
this kind of loading seems pathologic to me -- it never crossed my mind
to load/require "path/file" instead of first adding "path" to
`load-path' and then `load'ing "file". What use does this have? Or
rather, is it necessary (I imagine people might be trying to use this as
a poor man's module system)?

In any case, I'm obviously still missing a lot (such as how the case
with symbols defined outside load-path is handled or how the Help cross
references come into play -- they still don't work even with my "fix");
I'll try to look at the code some more.

  Štěpán





  reply	other threads:[~2010-07-27 10:07 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-24 11:56 bug#6716: 23.2; Setting `find-function-source-path' has no effect Štěpán Němec
2010-07-25 23:45 ` Stefan Monnier
2010-07-26  4:17   ` Štěpán Němec
2010-07-26  4:51     ` Štěpán Němec
2010-07-26 10:23     ` Stefan Monnier
2010-07-26 11:20       ` Štěpán Němec
2010-07-26 21:44         ` Stefan Monnier
2010-07-27 10:07           ` Štěpán Němec [this message]
2010-07-27 11:57             ` Stefan Monnier
2010-07-26 21:40 ` MON KEY
2010-07-27  9:39   ` Štěpán Němec
2010-07-28  1:38     ` MON KEY
2022-02-13 10:02 ` Lars Ingebrigtsen
2022-02-15 14:50   ` Štěpán Němec
2022-02-17 11:33     ` Lars Ingebrigtsen

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=87aapddyq6.fsf@gmail.com \
    --to=stepnem@gmail.com \
    --cc=6716@debbugs.gnu.org \
    --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).