From: Andrea Corallo Date: Sat, 16 Nov 2019 14:24:35 +0000 (+0100) Subject: rework comp-callref lambda list X-Git-Tag: emacs-28.0.90~2727^2~989 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a82f1929fef5072a4b04e326b467cca8a8a21c0e;p=emacs.git rework comp-callref lambda list --- diff --git a/lisp/emacs-lisp/comp.el b/lisp/emacs-lisp/comp.el index d62b4cbbe1a..40125103024 100644 --- a/lisp/emacs-lisp/comp.el +++ b/lisp/emacs-lisp/comp.el @@ -566,12 +566,13 @@ The basic block is returned regardless it was already declared or not." (comp-add-subr-to-relocs func) `(call ,func ,@args)) -(defun comp-callref (func &rest args) - "Emit a call usign narg abi for FUNC with ARGS." +(defun comp-callref (func nargs stack-off) + "Emit a call usign narg abi for FUNC. +NARGS is the number of arguments. +STACK-OFF is the index of the first slot frame involved." (comp-add-subr-to-relocs func) - `(callref ,func ,@(cl-loop with (nargs off) = args - repeat nargs - for sp from off + `(callref ,func ,@(cl-loop repeat nargs + for sp from stack-off collect (comp-slot-n sp)))) (cl-defun make-comp-mvar (&key slot (constant nil const-vld) type)