mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-20 19:50:24 +02:00
elisp: when, unless
* module/language/elisp/boot.el (when, unless): New macros.
This commit is contained in:
parent
12c00a0453
commit
c0652730bc
1 changed files with 8 additions and 0 deletions
|
@ -131,6 +131,14 @@
|
|||
#'(lambda () ,bodyform)
|
||||
#'(lambda () ,@unwindforms)))
|
||||
|
||||
(defmacro when (cond &rest body)
|
||||
`(if ,cond
|
||||
(progn ,@body)))
|
||||
|
||||
(defmacro unless (cond &rest body)
|
||||
`(when (not ,cond)
|
||||
,@body))
|
||||
|
||||
(defun symbolp (object)
|
||||
(%funcall (@ (guile) symbol?) object))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue