(values form nil))))
(defun compile-funcall (function args)
- (let* ((values-funcs (if *multiple-value-p* "values" "pv"))
- (arglist `(code "(" ,@(interleave (list* values-funcs
- (integer-to-string (length args))
- (mapcar #'ls-compile args))
- ", ")
- ")")))
+ (let* ((arglist (list* (if *multiple-value-p* '|values| '|pv|)
+ (length args)
+ (mapcar #'ls-compile args))))
(unless (or (symbolp function)
(and (consp function)
(member (car function) '(lambda oget))))
(error "Bad function designator `~S'" function))
(cond
((translate-function function)
- `(code ,(translate-function function) ,arglist))
+ `(call ,(make-symbol (translate-function function)) ,@arglist))
((and (symbolp function)
#+jscl (eq (symbol-package function) (find-package "COMMON-LISP"))
#-jscl t)
- `(code ,(ls-compile `',function) ".fvalue" ,arglist))
+ `(call (get ,(ls-compile `',function) "fvalue") ,@arglist))
#+jscl((symbolp function)
- `(code ,(ls-compile `#',function) ,arglist))
+ `(call ,(ls-compile `#',function) ,@arglist))
((and (consp function) (eq (car function) 'lambda))
- `(code ,(ls-compile `#',function) ,arglist))
+ `(call ,(ls-compile `#',function) ,@arglist))
((and (consp function) (eq (car function) 'oget))
- `(code ,(ls-compile function) ,arglist))
+ `(call ,(ls-compile function) ,@arglist))
(t
(error "Bad function descriptor")))))