Changeset 3973


Ignore:
Timestamp:
09/21/03 19:30:29 (20 years ago)
Author:
piso
Message:

SIMPLE-SUBTYPEP

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/j/src/org/armedbear/lisp/subtypep.lisp

    r3925 r3973  
    22;;;
    33;;; Copyright (C) 2003 Peter Graves
    4 ;;; $Id: subtypep.lisp,v 1.11 2003-09-20 16:16:52 piso Exp $
     4;;; $Id: subtypep.lisp,v 1.12 2003-09-21 19:30:29 piso Exp $
    55;;;
    66;;; This program is free software; you can redistribute it and/or
     
    134134
    135135(defun simple-subtypep (type1 type2)
    136   (assert (symbolp type1))
    137   (assert (symbolp type2))
    138   (if (memq type2 (supertypes type1))
    139       t
    140       (dolist (supertype (supertypes type1))
    141         (when (simple-subtypep supertype type2)
    142           (return t)))))
     136;;   (assert (symbolp type1))
     137;;   (assert (symbolp type2))
     138  (cond ((and (symbolp type1) (symbolp type2))
     139         (if (memq type2 (supertypes type1))
     140             t
     141             (dolist (supertype (supertypes type1))
     142               (when (simple-subtypep supertype type2)
     143                 (return t)))))
     144        (t
     145         nil)))
    143146
    144147(defun sub-interval-p (i1 i2)
Note: See TracChangeset for help on using the changeset viewer.