[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Syntax for optimizers in function definition



The way other such things are done on the Lispm now is with local
declarations.  These can either use LOCAL-DECLARE or look like Maclisp
local declarations at the front of the function, because anything of
the latter format is converted to the former.  Thus:

(local-declare (arglist a b c &rest d)
  (defun foo (&rest list-of-all-args)
	 (lexpr-funcall 'mumble t list-of-all-args)))

or

(defun foo (&rest list-of-all-args)
       (declare (arglist a b c &rest d))
       (lexpr-funcall 'mumble t list-of-all-args)))

I personally prefer the latter.

So we could have

(defun bar (x y)
       (declare (optimizers bar-into-quux-maybe bar-into-noop-maybe))
       ...)