[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: `append' vs. `nconc'
From: |
Emanuel Berg |
Subject: |
Re: `append' vs. `nconc' |
Date: |
Fri, 01 Jan 2016 14:23:26 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) |
Teemu Likonen <tlikonen@iki.fi> writes:
> LIST function creates a fresh list when it is
> evaluated, usually at runtime. The following applies
> to the Common Lisp language: Literal objects created
> with ' ` (QUOTE ...) "string" etc. might be created
> at compile time. Such objects might even be shared
> by all instances of such literal object. Common Lisp
> compilers are allowed to do that. So, the literal
> list '(a b c) in one place might actually become the
> very same (as in EQ) object as literal '(a b c) in
> somewhere else. If you mutate one object the results
> may show everywhere, which is not usually wanted.
>
> Even though it may not apply to Emacs Lisp or all
> Common Lisp compilers it's good habit to not mutate
> literally created objects. Be functional with them!
OK, then what functions, other than `nconc', are
mutators (or, how do you now)?
--
underground experts united
http://user.it.uu.se/~embe8573