User Tools


Variable +, ++, +++

Value Type

an object.

Initial Value

Description

The variables +, ++, and +++ are maintained by the Lisp read-eval-print loop to save forms that were recently evaluated.

The value of + is the last form that was evaluated, the value of ++ is the previous value of +, and +++ is the previous value of ++.

Examples

(+ 0 1)

1

(- 4 2)

2

(/ 9 3)

3

(list + ++ +++)

((/ 9 3) (- 4 2) (+ 0 1))

(defparameter *a* 1)

*A*

(defparameter *b* 2)

*B*

(defparameter *c* 3)

*B*

(defparameter *d* (list *a* *b* *c*))

*D*

(setf *a* 4 *b* 5 *c* 6 *d* (list a b c))

(4 5 6)

(list *a* *b* *c*)

(4 5 6)

(eval +++)

(1 2 3)

#.`(,@++ *d*)

(1 2 3 (1 2 3))

Affected By

See Also

Variable -, Variable *, Variable/, {\secref\TopLevelLoop}

Notes

None.


[[CLUS:TODO|Do not use this sidebar - nothing is linked here yet.]] [[CLUS:TODO|Click here instead.]] ----- * **[[CLUS:Common Lisp UltraSpec|(*) Common Lisp UltraSpec]]** * [[CLUS:TODO|TODO: E V E R Y T H I N G]] * **[[CL:ANSI Common Lisp|(*) ANSI Common Lisp]]** * [[CL:Introduction]] * [[CL:Syntax]] * [[CL:Evaluation and Compilation]] * [[CL:Types and Classes]] * [[CL:Data and Control Flow]] * [[CL:Iteration]] * [[CL:Objects]] * [[CL:Structures]] * [[CL:Conditions]] * [[CL:Symbols]] * [[CL:Packages]] * [[CL:Numbers]] * [[CL:Characters]] * [[CL:Conses]] * [[CL:Arrays]] * [[CL:Strings]] * [[CL:Sequences]] * [[CL:Hashtables]] * [[CL:Filenames]] * [[CL:Files]] * [[CL:Streams]] * [[CL:Printer]] * [[CL:Reader]] * [[CL:System Construction]] * [[CL:Environment]] * [[CL:Glossary]] * [[CL:Appendix]] * **[[Extensions|(*) Extensions]]** * [[Extensions:MOP]] * [[Extensions:ASDF]] * [[Extensions:UIOP]] * **[[Libraries|(*) Libraries]]** * [[Libraries:Quicklisp]] * **[[Implementations|(*) Implementations]]** * [[Implementations:SBCL]] * [[Implementations:CCL]] * [[Implementations:ECL]] * [[Implementations:ABCL]] * [[Implementations:LW]] * [[Implementations:ACL]] * [[Implementations:CLISP]] * [[Implementations:GCL]] * [[Implementations:JSCL]] * **[[Books|(*) Books]]** * [[Books:PCL|Practical Common Lisp]] * [[Books:CLR|Common Lisp Recipes]] * [[Books:ANSI CL|ANSI Common Lisp]] * [[Books:Gentle|Common Lisp: A Gentle (...)]] * [[Books:OL|On Lisp]] * [[Books:LOL|Let Over Lambda]] * **[[Documents|(*) Documents]]** * **[[Studying Material|(*) Studying Material]]** * **[[Blogs|(*) Blogs]]**