Subject: Re: bug#53024: 29.0.50; Wishlist: Byte-compile loaddefs.el?

From: Stefan Monnier <[email-masked]>
Date: Fri, 05 Aug 2022 09:44:24 -0400

> ;; Functions and variables with doc strings must be output separately,
> ;; so make-docfile can recognize them.  Most other things can be output
> ;; as byte-code.
>
> (put 'autoload 'byte-hunk-handler 'byte-compile-file-form-autoload)
> (defun byte-compile-file-form-autoload (form)

The comment is a bit off, indeed, but the code can't really be
simplified because the docstrings are still treated specially (to
implement `byte-compile-dynamic-docstrings`).

IIUC the comment predates `byte-compile-dynamic-docstrings`, which is
why they only mention `make-docfile`.  I've just updated the comments.

Admittedly, I think there are a few simplifications/improvements we
could now make in `bytecomp.el` (as mentioned in one comment), but the
benefit would be fairly minor, and it requires more significant changes
than just removing some unneeded code.

        Stefan