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

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

Weird error message "wrong-type-argument symbolp (quote foo)"


From: florian
Subject: Weird error message "wrong-type-argument symbolp (quote foo)"
Date: Wed, 10 Jun 2009 04:45:04 -0700 (PDT)
User-agent: G2/1.0

Dear wizards,

I would not have thought that such an error message was possible,
since (quote foo) should be the same as 'foo, hence, a symbol. I have
managed to produce it like this:

(let ((foo 1)
        (bar 2)
        (fubar 3))
    (dolist (var '('foo 'bar 'fubar))
      (message "%S's value is %d"
               var (symbol-value var))))


The following form, which should produce the same error, however, does
not complain (just as I expected):

(let ((var (quote foo)))
  (symbol-value var))

As expected, it also makes no difference if I write it as

(let ((var 'foo))
  (symbol-value var))

Also, symbolp and symbol-value do not complain if they get sth like
"(quote foo)" as argument. Can anybody point me to what on earth is
going on in the first form? Thanks so much!

Florian


reply via email to

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