Changeset 13762


Ignore:
Timestamp:
01/11/12 21:07:07 (9 years ago)
Author:
rschlatte
Message:

Fix short-method-combination object creation

... fixes a number of failing ANSI tests.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/abcl/src/org/armedbear/lisp/clos.lisp

    r13761 r13762  
    838838;;; StandardClass.java, but we cannot use make-instance and slot-value
    839839;;; yet.
    840 (defun make-short-method-combination (&key name documentation operator identity-with-one-argument)
    841   (let ((instance (std-allocate-instance (find-class 'short-method-combination))))
    842     (when name (setf (std-slot-value instance 'sys::name) name))
    843     (when documentation
    844       (setf (std-slot-value instance 'documentation) documentation))
    845     (when operator (setf (std-slot-value instance 'operator) operator))
    846     (when identity-with-one-argument
    847       (setf (std-slot-value instance 'identity-with-one-argument)
    848             identity-with-one-argument))
    849     instance))
    850840
    851841(defun make-long-method-combination (&key name documentation lambda-list
     
    934924          (getf (cddr whole) :operator name)))
    935925    `(progn
    936        (setf (get ',name 'method-combination-object)
    937              (make-short-method-combination
    938               :name ',name
    939               :operator ',operator
    940               :identity-with-one-argument ',identity-with-one-arg
    941               :documentation ',documentation))
    942        ',name)))
     926       ;; Class short-method-combination is defined in StandardClass.java.
     927       (let ((instance (std-allocate-instance
     928                        (find-class 'short-method-combination))))
     929         (setf (std-slot-value instance 'sys::name) ',name)
     930         (setf (std-slot-value instance 'documentation) ',documentation)
     931         (setf (std-slot-value instance 'operator) ',operator)
     932         (setf (std-slot-value instance 'identity-with-one-argument)
     933               ',identity-with-one-arg)
     934         (setf (get ',name 'method-combination-object) instance)
     935         ',name))))
    943936
    944937(defmacro define-method-combination (&whole form name &rest args)
Note: See TracChangeset for help on using the changeset viewer.