GNU bug report logs -
#5661
23.1.92; `find-library-name' should find a loaded library
Previous Next
Reported by: "Drew Adams" <drew.adams <at> oracle.com>
Date: Sun, 28 Feb 2010 23:13:02 UTC
Severity: wishlist
Tags: fixed
Fixed in version 26.1
Done: Lars 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 5661 in the body.
You can then email your comments to 5661 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org
:
bug#5661
; Package
emacs
.
(Sun, 28 Feb 2010 23:13:02 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
.
(Sun, 28 Feb 2010 23:13:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
emacs -Q
Put this code in a new file throw-a.el in a directory that is not in your
`load-path':
(defun foo () (message "foo"))
(provide 'throw-a)
In that same directory, do this:
M-x load-file RET throw-a.el RET
M-x load-library RET find-func RET
M-: (find-library-name "throw-a") RET
It should find the library (since it was loaded and thus provided), but instead
it raises an error:
Debugger entered--Lisp error: (error "Can't find library throw-a")
signal(error ("Can't find library throw-a"))
error("Can't find library %s" "throw-a")
find-library-name("throw-a")
eval((find-library-name "throw-a"))
eval-expression((find-library-name "throw-a") nil)
call-interactively(eval-expression nil nil)
The doc string says nothing about searching only the `load-path'. It's
reasonable to think that this should be able to find the library either by
checking loaded libraries or by searching the `load-path'.
Consider, for example, using `finder-commentary' after having loaded the library
using `load-file' but not having the library in the `load-path'. The library is
known to the current session, but Emacs isn't smart enough to find it.
Severity set to 'wishlist' from 'normal'
Request was from
Glenn Morris <rgm <at> gnu.org>
to
control <at> debbugs.gnu.org
.
(Tue, 02 Mar 2010 19:47:02 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#5661
; Package
emacs
.
(Wed, 27 Apr 2016 21:24:02 GMT)
Full text and
rfc822 format available.
Message #10 received at 5661 <at> debbugs.gnu.org (full text, mbox):
"Drew Adams" <drew.adams <at> oracle.com> writes:
> Put this code in a new file throw-a.el in a directory that is not in your
> `load-path':
>
> (defun foo () (message "foo"))
> (provide 'throw-a)
>
> In that same directory, do this:
>
> M-x load-file RET throw-a.el RET
> M-x load-library RET find-func RET
> M-: (find-library-name "throw-a") RET
>
> It should find the library (since it was loaded and thus provided), but instead
> it raises an error:
>
> Debugger entered--Lisp error: (error "Can't find library throw-a")
> signal(error ("Can't find library throw-a"))
> error("Can't find library %s" "throw-a")
> find-library-name("throw-a")
> eval((find-library-name "throw-a"))
> eval-expression((find-library-name "throw-a") nil)
> call-interactively(eval-expression nil nil)
>
> The doc string says nothing about searching only the `load-path'. It's
> reasonable to think that this should be able to find the library either by
> checking loaded libraries or by searching the `load-path'.
That would be nice. But does Emacs have a record of all files it has
done `load-file' on somewhere?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#5661
; Package
emacs
.
(Wed, 27 Apr 2016 21:30:02 GMT)
Full text and
rfc822 format available.
Message #13 received at 5661 <at> debbugs.gnu.org (full text, mbox):
> > The doc string says nothing about searching only the `load-path'. It's
> > reasonable to think that this should be able to find the library either
> by
> > checking loaded libraries or by searching the `load-path'.
>
> That would be nice. But does Emacs have a record of all files it has
> done `load-file' on somewhere?
Sorry, I'm reading these really quickly. But does `load-history'
apply here?
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#5661
; Package
emacs
.
(Wed, 27 Apr 2016 21:38:01 GMT)
Full text and
rfc822 format available.
Message #16 received at 5661 <at> debbugs.gnu.org (full text, mbox):
Drew Adams <drew.adams <at> oracle.com> writes:
>> > The doc string says nothing about searching only the `load-path'. It's
>> > reasonable to think that this should be able to find the library either
>> by
>> > checking loaded libraries or by searching the `load-path'.
>>
>> That would be nice. But does Emacs have a record of all files it has
>> done `load-file' on somewhere?
>
> Sorry, I'm reading these really quickly. But does `load-history'
> apply here?
Indeed it seems like that should do the trick. Does anybody object to
me extending `find-library-name' to check with `load-history' after it's
gone through the paths it's currently searching?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#5661
; Package
emacs
.
(Sun, 01 May 2016 16:40:02 GMT)
Full text and
rfc822 format available.
Message #19 received at 5661 <at> debbugs.gnu.org (full text, mbox):
Lars Ingebrigtsen <larsi <at> gnus.org> writes:
> Drew Adams <drew.adams <at> oracle.com> writes:
>
>>> > The doc string says nothing about searching only the `load-path'. It's
>>> > reasonable to think that this should be able to find the library either
>>> by
>>> > checking loaded libraries or by searching the `load-path'.
>>>
>>> That would be nice. But does Emacs have a record of all files it has
>>> done `load-file' on somewhere?
>>
>> Sorry, I'm reading these really quickly. But does `load-history'
>> apply here?
>
> Indeed it seems like that should do the trick. Does anybody object to
> me extending `find-library-name' to check with `load-history' after it's
> gone through the paths it's currently searching?
Nobody seemed to object, so I've now implemented it. It was more
twiddly than I assumed.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Added tag(s) fixed.
Request was from
Lars Ingebrigtsen <larsi <at> gnus.org>
to
control <at> debbugs.gnu.org
.
(Sun, 01 May 2016 16:40:02 GMT)
Full text and
rfc822 format available.
bug marked as fixed in version 25.2, send any further explanations to
5661 <at> debbugs.gnu.org and "Drew Adams" <drew.adams <at> oracle.com>
Request was from
Lars Ingebrigtsen <larsi <at> gnus.org>
to
control <at> debbugs.gnu.org
.
(Sun, 01 May 2016 16:40: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
.
(Mon, 30 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:02 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:02 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: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
.
(Sun, 01 Jan 2017 12:24:19 GMT)
Full text and
rfc822 format available.
This bug report was last modified 8 years and 228 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.