Changeset 6713


Ignore:
Timestamp:
Jun 12, 2007, 1:01:13 PM (17 years ago)
Author:
Gary Byers
Message:

remove-slot-initargs: a little better, but should be able to recognize
the case where there are no initargs and not cons a fresh list each
time.


File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/ide-1.0/ccl/examples/objc-clos.lisp

    r6684 r6713  
    708708(defun remove-slot-initargs (class initargs)
    709709  (let* ((slot-initargs (class-slot-initargs class))) ; cache this, maybe
     710    (collect ((new-initargs))
    710711    (loop for l = initargs then (cddr l)
    711           when (null l) do (return-from remove-slot-initargs new-initargs)
     712          when (null l) do (return-from remove-slot-initargs (new-initargs))
    712713          unless (member (first l)  slot-initargs :test #'eq)
    713             append (list (first l) (second l))  into new-initargs)))
     714          do
     715          (new-initargs (car l))
     716          (new-initargs (cadr l))))))
    714717
    715718(defun create-foreign-instance-slot-vector (class)
Note: See TracChangeset for help on using the changeset viewer.