[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Refactoring of emacs-lisp/autoload.el

From: Alan Mackenzie
Subject: Re: Refactoring of emacs-lisp/autoload.el
Date: Thu, 14 Aug 2008 13:17:39 +0000
User-agent: Mutt/1.5.9i

Hi, Stefan!

On Wed, Aug 13, 2008 at 04:31:14PM -0400, Stefan Monnier wrote:
> > OK.  I haven't yet characterised fully the criterion for a file being
> > in this list.  I'm looking at that now.

> Normally, all files should appear in loaddefs.el: either they have their
> own section or they're in the "nothing to declare" section.
> If there are a couple files not mentioned there, it's not tragic, tho.

Ah, got it!  It was just I thought I'd seen a file with its own section
which was also in the "innocent" section at the end.  I've had a look for
this, and can't find it.  So I must have been mistaken.

> The goal is that running "cd emacs/lisp; make autoloads" after
> loaddefs.el has just been updated should only need to scan loaddefs.el,
> and check the timestamp of all the .el files, and can then return
> without reading any of the other (unchanged) elisp files, so that "make
> autoloads" is almost immediate when it has nothing to do.

OK.  This is obviously very important.  The patch I posted here isn't up
to scratch for that.  I'll need to improve it.

> > My strategy when inserting a new entry into loaddefs.el is to start
> > searching from the current position in that file.  So if the source
> > files are processed in alphabetical order, the newer autoload.el
> > should be just as fast (or, at least, fast enough).

> Yes, that sounds fine.

What I'll be doing is sorting the "no-autoloads" list so that it's in the
same order as the file entries.  I can then loop through all the files,
testing in turn whether the file was a "no-autoload" or had its own
section, and take the appropriate action.  That will mean never having to
search loaddefs.el for an entry, and not having to use `member' in the
"no-autoloads" list, since I will be stepping through both from start to

>         Stefan

Alan Mackenzie (Nuremberg, Germany).

reply via email to

[Prev in Thread] Current Thread [Next in Thread]