Include alexandria library in the project
Discard useless once-only macro and replace it by alexandria's implementation
This commit is contained in:
parent
eaedaf8a35
commit
75aae52cfe
2 changed files with 2 additions and 9 deletions
|
|
@ -9,7 +9,7 @@
|
|||
(:nicknames :utils)
|
||||
(:export :it :aif :awhen
|
||||
:safe-first :safe-list
|
||||
:group :once-only
|
||||
:group
|
||||
:restartable
|
||||
:add-hook :remove-hook :run-hook
|
||||
:update-current-time :get-delta-time
|
||||
|
|
@ -53,14 +53,6 @@
|
|||
(nreverse (cons source acc))))))
|
||||
(if source (rec source nil) nil)))
|
||||
|
||||
(defmacro once-only ((&rest names) &body body)
|
||||
"Evaluate the symbols in `names' only once, for use in a macro, as per Peter Siebel's Practical Common-Lisp."
|
||||
(let ((gensyms (loop for n in names collect (gensym))))
|
||||
`(let (,@(loop for g in gensyms collect `(,g (gensym))))
|
||||
`(let (,,@(loop for g in gensyms for n in names collect ``(,,g ,,n)))
|
||||
,(let (,@(loop for n in names for g in gensyms collect `(,n ,g)))
|
||||
,@body)))))
|
||||
|
||||
(defmacro restartable (unprotected &body body)
|
||||
"Provide a Continue restart unless `unprotected' is t."
|
||||
`(if ,unprotected
|
||||
|
|
|
|||
1
stoe.asd
1
stoe.asd
|
|
@ -19,6 +19,7 @@
|
|||
:author "Renaud Casenave-Péré"
|
||||
:license "GPL3"
|
||||
:depends-on (:swank
|
||||
:alexandria
|
||||
:glop
|
||||
:cl-opengl)
|
||||
:components ((:module "src"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue