![[LISPWORKS]](/image.pl?url=http%3a%2f%2fwww.lispworks.com%2fdocumentation%2fHyperSpec%2fBody%2f..%2fGraphics%2fLWSmall.gif&f=jpg&w=240)
![[Common Lisp HyperSpec (TM)]](/image.pl?url=http%3a%2f%2fwww.lispworks.com%2fdocumentation%2fHyperSpec%2fBody%2f..%2fGraphics%2fCLHS_Sm.gif&f=jpg&w=240)
Syntax:
quoteobject =>object
Arguments and Values:
object---anobject; not evaluated.
Description:
Thequotespecial operator just returnsobject.
The consequences are undefined ifliteralobjects (includingquoted objects) are destructively modified.
Examples:
(setq a 1) => 1 (quote (setq a 3)) => (SETQ A 3) a => 1 'a => A ''a => (QUOTE A) '''a => (QUOTE (QUOTE A)) (setq a 43) => 43 (list a (cons a 3)) => (43 (43 . 3)) (list (quote a) (quote (cons a 3))) => (A (CONS A 3)) 1 => 1 '1 => 1 "foo" => "foo" '"foo" => "foo" (car '(a b)) => A '(car '(a b)) => (CAR (QUOTE (A B))) #(car '(a b)) => #(CAR (QUOTE (A B))) '#(car '(a b)) => #(CAR (QUOTE (A B)))
Affected By: None.
Exceptional Situations: None.
See Also:
Section 3.1 (Evaluation),Section 2.4.3 (Single-Quote),Section 3.2.1 (Compiler Terminology)
Notes:
The textual notation'object is equivalent to(quoteobject); seeSection 3.2.1 (Compiler Terminology).
Someobjects, calledself-evaluating objects, do not require quotation byquote. However,symbols andlists are used to represent parts of programs, and so would not be useable as constant data in a program withoutquote. Sincequote suppresses theevaluation of theseobjects, they become data rather than program.