simple-bit-vector simple-string simple-vector single-float standard-char
stream string symbol t unsigned-byte vector))
-(defun split-declarations (body args calls-next-method-p)
+(defun split-declarations (body args maybe-reads-params-p)
(let ((inner-decls nil)
(outer-decls nil)
decl)
;; involved, to prevent compiler
;; warnings about ignored args being
;; read.
- (unless (and calls-next-method-p
+ (unless (and maybe-reads-params-p
(eq (car dname) 'ignore))
(push var outers))
(push var inners)))
(defun name-method-lambda (method-lambda)
(let ((method-name (body-method-name (cddr method-lambda))))
(if method-name
- `(named-lambda ,method-name ,(rest method-lambda))
+ `(named-lambda (slow-method ,method-name) ,(rest method-lambda))
method-lambda)))
(defun make-method-initargs-form-internal (method-lambda initargs env)
(initargs body req-args lmf-params restp)
(multiple-value-bind (outer-decls inner-decls body-sans-decls)
(split-declarations
- body req-args (getf (cdr lmf-params) :call-next-method-p))
+ body req-args (or (getf (cdr lmf-params) :call-next-method-p)
+ (getf (cdr lmf-params) :setq-p)))
(let* ((rest-arg (when restp '.rest-arg.))
(args+rest-arg (if restp
(append req-args (list rest-arg))
:fast-function
(,(if (body-method-name body) 'named-lambda 'lambda)
,@(when (body-method-name body)
- (list (body-method-name body))) ; function name
+ ;; function name
+ (list (cons 'fast-method (body-method-name body))))
(.pv-cell. .next-method-call. ,@args+rest-arg) ; function args
;; body of the function
(declare (ignorable .pv-cell. .next-method-call.))
(apply fmf pv-cell nmc (nconc args (list rest))))
(apply fmf pv-cell nmc method-args)))))
(let* ((fname (method-function-get fmf :name))
- (name `(,(or (get (car fname) 'method-sym)
- (setf (get (car fname) 'method-sym)
- (let ((str (symbol-name (car fname))))
- (if (string= "FAST-" str :end2 5)
- (format-symbol *pcl-package* (subseq str 5))
- (car fname)))))
- ,@(cdr fname))))
+ (name (cons 'slow-method (cdr fname))))
(set-fun-name method-function name))
(setf (method-function-get method-function :fast-function) fmf)
method-function))