Function: cl--optimize
cl--optimize is a byte-compiled function defined in cl-macs.el.gz.
Signature
(cl--optimize F ARGS &rest QUALITIES)
Documentation
Serve 'cl-optimize' in function declarations.
Example:
(defun foo (x)
(declare (cl-optimize (speed 3) (safety 0)))
x)
Source Code
;; Defined in /usr/src/emacs/lisp/emacs-lisp/cl-macs.el.gz
(defun cl--optimize (f _args &rest qualities)
"Serve 'cl-optimize' in function declarations.
Example:
(defun foo (x)
(declare (cl-optimize (speed 3) (safety 0)))
x)"
;; FIXME this should make use of `cl--declare-stack' but I suspect
;; this mechanism should be reviewed first.
(cl-loop for (qly val) in qualities
do (cl-ecase qly
(speed
(setf cl--optimize-speed val)
(byte-run--set-speed f nil val))
(safety
(setf cl--optimize-safety val)))))