[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ;;;###autoload declarations
From: |
Emanuel Berg |
Subject: |
Re: ;;;###autoload declarations |
Date: |
Fri, 23 Jun 2023 20:26:07 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
Michael Heerdegen wrote:
>> It then seems to me that although autoloading is intended
>> as described, technically it is untrue, because everything
>> seems to be evaluated all in one go.
>>
>> What is going on ?
>
> You need to generate a loaddefs file.
If we change "all in one go" into "sequentially" or "in the
order specified by the Lisp syntax" then - that's the natural
order of things.
So ;;;###autoload is obviously an exception ... but anyway, it
works like this, as described in the documentation -
The autoload facility lets you register the existence of
a function or macro, but put off loading the file that
defines it. The first call to the function automatically
loads the proper library, in order to install the real
definition and other associated code, then runs the real
definition as if it had been loaded all along.
<https://www.gnu.org/software/emacs/manual/html_node/elisp/Autoload.html>
(info "(elisp) Autoload")
However, what I can see it fails to address why this is at all
desirable to do and, assuming it is, in what cases more
precisely it is useful.
Which I think is a candidate for the second if not
first paragraph! If you agree.
--
underground experts united
https://dataswamp.org/~incal