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

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

Re: Why doesn't nconc change my variable?


From: Pascal J. Bourguignon
Subject: Re: Why doesn't nconc change my variable?
Date: Sun, 05 Oct 2014 20:14:22 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Marcin Borkowski <mbork@wmi.amu.edu.pl> writes:

> Does it mean that Pascal's earlier response was right?  Now that I'm
> thinking about it, this makes sense: an empty list is (I would guess) a
> NUL pointer, 

NO!  There is no pointer in lisp!

An empty list is the symbol nil!

    (symbolp (list))     --> t
    (consp   (list))     --> nil
    (symbol-name (list)) --> "nil"

    (symbolp (list 1))   --> nil
    (consp   (list 1))   --> t
    (car     (list 1))   --> 1
    (cdr     (list 1))   --> nil



-- 
__Pascal Bourguignon__                 http://www.informatimago.com/
“The factory of the future will have only two employees, a man and a
dog. The man will be there to feed the dog. The dog will be there to
keep the man from touching the equipment.” -- Carl Bass CEO Autodesk


reply via email to

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