help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Speeding up Emacs load time


From: Rustom Mody
Subject: Re: Speeding up Emacs load time
Date: Sun, 30 Jun 2013 07:04:01 -0700 (PDT)
User-agent: G2/1.0

On Sunday, June 30, 2013 6:16:41 PM UTC+5:30, Emanuel Berg wrote:
> Rustom Mody  writes:
> > And that means that Elisp-hacking means frequent restarts of
> > Emacs.
> 
> Say what?! I do Elisp all the time and I *never* restart Emacs.
> Why do you have to restart it?
> You know about `eval-defun', `eval-last-sexp`, `load-file`, etc.?

Yeah I know about those.  What's missing is un-defun unload etc.

What happens in a functional language is that before each load from file to 
interpreter, the interpreter slate is wiped clean. So there is no cruft.

Yeah there is unload-feature. For that you need to be using require/provide

Let me repeat the scenario again (which has bitten me quite a few times):

I am hacking an elisp function called foo
I keep hacking on it till I get it right
Now I am satisfied and change its name to long-proper-name-for-foo
I change (what I think are) all refs to foo to long-proper-name-for-foo.

Note that at this point the lisp namespace contains two names foo and 
long-proper-name-for-foo defined to the same function.

It (seems to) run
The next time I start emacs it does not run because I find that I had not 
renamed all foo-references to long-proper-name-for-foo.

As for being a functional language: this is a moving target.
In the 1960 Lisp (and maybe APL) were THE functional languages.
By 1980s it was clear that there were two major mistakes in lisp 
- lambda not first class
- double name space for functions and variables

Scheme cleaned up both these errors, CL cleaned up only the first.
And scheme became the benchmark for being an FPL

Likewise today its haskell.

At the other end of the spectrum, FORTRAN, if you open up the acronym, shows 
that its inventors imagined it to be something like a functional language.
A fair evaluation of that viewpoint is that it was right in 1958 but became 
wrong (obsolete) in 1960 when lisp came
 


reply via email to

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