Changeset 12761


Ignore:
Timestamp:
Sep 4, 2009, 10:53:10 PM (10 years ago)
Author:
gb
Message:

When trying to determine whether a call to SLOT-VALUE-USING-CLASS,
SETF thereof, or SLOT-MAKUNBOUND-USING-CLASS can be avoided, check the
slot's allocation and call the gf if the allocation is non-standard.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/level-1/l1-clos-boot.lisp

    r12500 r12761  
    27432743           (eq *standard-effective-slot-definition-class-wrapper*
    27442744               (instance.class-wrapper slotd))
    2745            (eq *standard-class-wrapper* (instance.class-wrapper class)))
     2745           (eq *standard-class-wrapper* (instance.class-wrapper class))
     2746           (let* ((allocation (standard-effective-slot-definition.location slotd)))
     2747             (or (eq allocation :instance) (eq allocation :class))))
    27462748    (%std-slot-vector-value (instance-slots instance) slotd)
    27472749    (if (= (the fixnum (typecode instance)) target::subtag-struct)
     
    27882790           (eq *standard-effective-slot-definition-class-wrapper*
    27892791               (instance.class-wrapper slotd))
    2790            (eq *standard-class-wrapper* (instance.class-wrapper class)))
     2792           (eq *standard-class-wrapper* (instance.class-wrapper class))
     2793           (let* ((allocation (standard-effective-slot-definition.allocation slotd)))
     2794             (or (eq allocation :instance) (eq allocation :class))))
    27912795    ;; Not safe to use instance.slots here, since the instance is not
    27922796    ;; definitely of type SUBTAG-INSTANCE.  (Anyway, INSTANCE-SLOTS
     
    29042908           (eq *standard-effective-slot-definition-class-wrapper*
    29052909               (instance.class-wrapper slotd))
    2906            (eq *standard-class-wrapper* (instance.class-wrapper class)))
     2910           (eq *standard-class-wrapper* (instance.class-wrapper class))
     2911           (let* ((allocation (standard-slot-definition.allocation slotd)))
     2912             (or (eq allocation :class)
     2913                 (eq allocation :instance))))
    29072914    (%std-slot-vector-boundp (instance-slots instance) slotd)
    29082915    (slot-boundp-using-class class instance slotd)))
Note: See TracChangeset for help on using the changeset viewer.