* Re: master 263ab75: ; Fix recent byte-compiler warning in dnd.el again
[not found] ` <20200507174022.5B7BD20A15@vcs0.savannah.gnu.org>
@ 2020-05-07 19:05 ` Stefan Monnier
2020-05-07 20:21 ` Basil L. Contovounesios
0 siblings, 1 reply; 5+ messages in thread
From: Stefan Monnier @ 2020-05-07 19:05 UTC (permalink / raw)
To: emacs-devel; +Cc: Basil L. Contovounesios
> diff --git a/lisp/dnd.el b/lisp/dnd.el
> index c185794..102bc75 100644
> --- a/lisp/dnd.el
> +++ b/lisp/dnd.el
> @@ -101,6 +101,8 @@ is what has been dropped. Returns ACTION."
> (throw 'done t)))
> nil)
> (catch 'done
> + ;; Autoloaded but the byte-compiler still complains.
> + (declare-function browse-url-select-handler "browse-url" (url))
> (let ((browser (browse-url-select-handler url)))
> (when browser
> (setq ret 'private)
It complains because the ;;;###autoload cookie had not yet been turned
into an actual autoload in `lisp/loaddefs.el`.
IOW what was missing was `cd lisp; make autoloads`.
I also get caught by those things every once in a while.
It would be good to find a way to automatically guess when to run `make autoloads`.
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: master 263ab75: ; Fix recent byte-compiler warning in dnd.el again
2020-05-07 19:05 ` master 263ab75: ; Fix recent byte-compiler warning in dnd.el again Stefan Monnier
@ 2020-05-07 20:21 ` Basil L. Contovounesios
2020-05-07 20:55 ` Stefan Monnier
0 siblings, 1 reply; 5+ messages in thread
From: Basil L. Contovounesios @ 2020-05-07 20:21 UTC (permalink / raw)
To: Stefan Monnier; +Cc: emacs-devel
Stefan Monnier <monnier@iro.umontreal.ca> writes:
>> diff --git a/lisp/dnd.el b/lisp/dnd.el
>> index c185794..102bc75 100644
>> --- a/lisp/dnd.el
>> +++ b/lisp/dnd.el
>> @@ -101,6 +101,8 @@ is what has been dropped. Returns ACTION."
>> (throw 'done t)))
>> nil)
>> (catch 'done
>> + ;; Autoloaded but the byte-compiler still complains.
>> + (declare-function browse-url-select-handler "browse-url" (url))
>> (let ((browser (browse-url-select-handler url)))
>> (when browser
>> (setq ret 'private)
>
> It complains because the ;;;###autoload cookie had not yet been turned
> into an actual autoload in `lisp/loaddefs.el`.
> IOW what was missing was `cd lisp; make autoloads`.
That was my first thought as well, but 'make bootstrap' was still
complaining after verifying
$ grep browse-url-select-handler lisp/loaddefs.el
(autoload 'browse-url-select-handler "browse-url" "\
so I assumed the warning was due to bootstrapping order and added the
declaration anyway.
> I also get caught by those things every once in a while.
> It would be good to find a way to automatically guess when to run `make autoloads`.
Is it run in time as part of 'make bootstrap'?
--
Basil
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: master 263ab75: ; Fix recent byte-compiler warning in dnd.el again
2020-05-07 20:21 ` Basil L. Contovounesios
@ 2020-05-07 20:55 ` Stefan Monnier
2020-05-07 23:12 ` Basil L. Contovounesios
0 siblings, 1 reply; 5+ messages in thread
From: Stefan Monnier @ 2020-05-07 20:55 UTC (permalink / raw)
To: Basil L. Contovounesios; +Cc: emacs-devel
>> It complains because the ;;;###autoload cookie had not yet been turned
>> into an actual autoload in `lisp/loaddefs.el`.
>> IOW what was missing was `cd lisp; make autoloads`.
>
> That was my first thought as well, but 'make bootstrap' was still
> complaining after verifying
>
> $ grep browse-url-select-handler lisp/loaddefs.el
> (autoload 'browse-url-select-handler "browse-url" "\
Hmm... that's odd.
I removed the declare-function, then did:
(cd lisp; make autoloads); make`
and the warning was still gone.
I can imagine the warning sticking around if you do
cd lisp; make autoloads; make
because then you only recompile `lisp/dnd.el` without first rebuilding
Emacs with the new `lisp/loaddefs.el`, but in the case of bootstrap
I can't see why the warning would linger (my machine's weak CPU makes
it much too painful to do a bootstrap so I haven't tested that case).
> so I assumed the warning was due to bootstrapping order and added the
> declaration anyway.
I guess that's possible. In that case the warning should disappear
when lisp/ldefs-boot.el is updated.
>> I also get caught by those things every once in a while.
>> It would be good to find a way to automatically guess when to run `make autoloads`.
> Is it run in time as part of 'make bootstrap'?
Yes.
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: master 263ab75: ; Fix recent byte-compiler warning in dnd.el again
2020-05-07 20:55 ` Stefan Monnier
@ 2020-05-07 23:12 ` Basil L. Contovounesios
2020-06-13 15:16 ` Basil L. Contovounesios
0 siblings, 1 reply; 5+ messages in thread
From: Basil L. Contovounesios @ 2020-05-07 23:12 UTC (permalink / raw)
To: Stefan Monnier; +Cc: emacs-devel
Stefan Monnier <monnier@iro.umontreal.ca> writes:
>> so I assumed the warning was due to bootstrapping order and added the
>> declaration anyway.
>
> I guess that's possible. In that case the warning should disappear
> when lisp/ldefs-boot.el is updated.
Okay, I'll keep an eye out for that and try removing the declaration
then.
Thanks,
--
Basil
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: master 263ab75: ; Fix recent byte-compiler warning in dnd.el again
2020-05-07 23:12 ` Basil L. Contovounesios
@ 2020-06-13 15:16 ` Basil L. Contovounesios
0 siblings, 0 replies; 5+ messages in thread
From: Basil L. Contovounesios @ 2020-06-13 15:16 UTC (permalink / raw)
To: Stefan Monnier; +Cc: emacs-devel
"Basil L. Contovounesios" <contovob@tcd.ie> writes:
> Stefan Monnier <monnier@iro.umontreal.ca> writes:
>
>>> so I assumed the warning was due to bootstrapping order and added the
>>> declaration anyway.
>>
>> I guess that's possible. In that case the warning should disappear
>> when lisp/ldefs-boot.el is updated.
>
> Okay, I'll keep an eye out for that and try removing the declaration
> then.
Now done:
; Fix some recent byte-compilation warnings
6d6ec1bc1e 2020-06-01 16:56:26 +0100
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=6d6ec1bc1e784af786cc0436f54211095bf7a952
--
Basil
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2020-06-13 15:16 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20200507174021.29070.24637@vcs0.savannah.gnu.org>
[not found] ` <20200507174022.5B7BD20A15@vcs0.savannah.gnu.org>
2020-05-07 19:05 ` master 263ab75: ; Fix recent byte-compiler warning in dnd.el again Stefan Monnier
2020-05-07 20:21 ` Basil L. Contovounesios
2020-05-07 20:55 ` Stefan Monnier
2020-05-07 23:12 ` Basil L. Contovounesios
2020-06-13 15:16 ` Basil L. Contovounesios
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).