[Top][All Lists]

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

Re: applying changes in .emacs

From: Kevin Rodgers
Subject: Re: applying changes in .emacs
Date: Mon, 29 Aug 2005 14:15:46 -0600
User-agent: Mozilla Thunderbird 0.9 (X11/20041105)

Eli Zaretskii wrote:
>>From: don provan <address@hidden>
>>Date: Mon, 29 Aug 2005 00:35:25 -0700
>>Wow. I would have said .emacs code is broken if it cannot be
>>re-evaluated without causing bad side effects, so I must be missing
> You are not missing anything, I think.  Simply put, typical .emacs
> code is written assuming that it is evaluated only once, when Emacs
> starts.  While that might be a bad assumption for general-purpose Lisp
> code, what one puts in .emacs is not general-purpose code, and in any
> case, that's how people tend to do it.
>>Can you give some examples and explain why they can't be avoided?
>>About the only thing I'm aware of doing is adding duplicate entries
>>to some lists, and even that I could avoid if I thought the effect
>>would amount to something bad.
> Adding things to a list is one typical example (adding a hook function
> is a frequently seen variant of this).  Doing something if some symbol
> is not bound or if some feature is not available (meaning a package is
> not loaded) is another.  There's more.

For example, if you want to double the default value of some variable:

(setq max-lisp-eval-depth (* 2 max-lisp-eval-depth))

Kevin Rodgers

reply via email to

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