unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Emanuel Berg <incal@dataswamp.org>
To: help-gnu-emacs@gnu.org
Subject: Re: ;;;###autoload declarations
Date: Fri, 23 Jun 2023 20:26:07 +0200	[thread overview]
Message-ID: <87sfaivxvk.fsf@dataswamp.org> (raw)
In-Reply-To: 87v8few484.fsf@web.de

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




  parent reply	other threads:[~2023-06-23 18:26 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-23 11:09 ;;;###autoload declarations uzibalqa
2023-06-23 16:08 ` Michael Heerdegen
2023-06-23 16:42   ` uzibalqa
2023-06-24  2:02     ` Michael Heerdegen
2023-06-24 11:27       ` uzibalqa
2023-06-25  1:55         ` Michael Heerdegen
2023-06-23 18:26   ` Emanuel Berg [this message]
2023-06-26 13:27     ` [External] : " Drew Adams
2023-06-30 15:35       ` Emanuel Berg
2023-07-03 15:59         ` Drew Adams

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=87sfaivxvk.fsf@dataswamp.org \
    --to=incal@dataswamp.org \
    --cc=help-gnu-emacs@gnu.org \
    /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.
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).