Changeset 9340


Ignore:
Timestamp:
May 1, 2008, 8:15:21 AM (12 years ago)
Author:
gz
Message:

Make nx-form-typep not err with compile-time classes

Location:
branches/working-0711/ccl
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/working-0711/ccl/compiler/nx0.lisp

    r9328 r9340  
    25682568  (setq type (nx-target-type (type-expand type)))
    25692569  (if (constantp arg)
    2570     (typep (nx-unquote arg) type)
    2571     (subtypep (nx-form-type arg env) type)))
     2570    (typep (nx-unquote arg) type env)
     2571    (subtypep (nx-form-type arg env) type env)))
    25722572
    25732573
  • branches/working-0711/ccl/level-1/sysutils.lisp

    r9117 r9340  
    295295(defun typep (object type &optional env)
    296296  "Is OBJECT of type TYPE?"
    297   (declare (ignore env))
    298297  (let* ((pred (if (symbolp type) (type-predicate type))))
    299298    (if pred
    300299      (funcall pred object)
    301       (values (%typep object type)))))
     300      (values (%typep object (if env (specifier-type type env) type))))))
    302301
    303302
     
    342341
    343342(defun subtypep (type1 type2 &optional env)
    344   (declare (ignore env))
    345343  "Return two values indicating the relationship between type1 and type2.
    346344  If values are T and T, type1 definitely is a subtype of type2.
    347345  If values are NIL and T, type1 definitely is not a subtype of type2.
    348346  If values are NIL and NIL, it couldn't be determined."
    349   (csubtypep (specifier-type type1) (specifier-type type2)))
     347  (csubtypep (specifier-type type1 env) (specifier-type type2 env)))
    350348
    351349
Note: See TracChangeset for help on using the changeset viewer.