# HG changeset patch # User Richard M. Stallman # Date 1011149235 0 # Node ID c3e528c6c110c7cdd995208369ba827597a1c06e # Parent 5a0d18142c4a62f6088aa1fa3298aa646481f73b (Autoload): Explain how to autoload function definitions that use unusual macros. diff -r 5a0d18142c4a -r c3e528c6c110 lispref/loading.texi --- a/lispref/loading.texi Wed Jan 16 02:36:53 2002 +0000 +++ b/lispref/loading.texi Wed Jan 16 02:47:15 2002 +0000 @@ -478,6 +478,18 @@ documentation string in the @file{etc/DOC} file. @xref{Building Emacs}. See also the commentary in @file{lib-src/make-docfile.c}. + If you write a function definition with an unusual macro that is not +one of the known and recognized function definition methods, use of an +ordinary magic autoload comment would copy the whole definition into +@code{loaddefs.el}. That is not desirable. You can put the desired +@code{autoload} call into @code{loaddefs.el} instead by writing this: + +@smallexample +;;;###autoload (autoload 'foo "myfile") +(mydefunmacro foo + ...) +@end smallexample + @node Repeated Loading @section Repeated Loading @cindex repeated loading