1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-20 11:40:18 +02:00

new elisp special form `%funcall'

* module/language/elisp/compile-tree-il.scm (compile-%funcall): New
  procedure.
* module/language/elisp/runtime/function-slot.scm: Update module
  definition.
This commit is contained in:
BT Templeton 2011-07-25 12:26:44 -04:00
parent 5bcc6d9e70
commit d273b82656
2 changed files with 10 additions and 0 deletions

View file

@ -49,6 +49,7 @@
compile-defun
#{compile-`}#
compile-quote
compile-%funcall
compile-%set-lexical-binding-mode))
;;; Certain common parameters (like the bindings data structure or
@ -821,6 +822,13 @@
((,val)
(make-const loc val))))
(defspecial %funcall (loc args)
(pmatch args
((,function . ,arguments)
(make-application loc
(compile-expr function)
(map compile-expr arguments)))))
(defspecial %set-lexical-binding-mode (loc args)
(pmatch args
((,val)

View file

@ -40,6 +40,7 @@
(compile-defmacro . defmacro)
(#{compile-`}# . #{`}#)
(compile-quote . quote)
(compile-%funcall . %funcall)
(compile-%set-lexical-binding-mode
. %set-lexical-binding-mode)))
#:duplicates (last)
@ -63,6 +64,7 @@
defmacro
#{`}#
quote
%funcall
%set-lexical-binding-mode)
;; functions
#:re-export (apply)