220 |
`(((SUBTYPEP ,type1 ,type2) cl-user::==> ,sub ,valid)) |
`(((SUBTYPEP ,type1 ,type2) cl-user::==> ,sub ,valid)) |
221 |
nil))) |
nil))) |
222 |
|
|
223 |
|
(defun subtypep-and-contrapositive-are-consistent (t1 t2) |
224 |
|
(multiple-value-bind (sub1 success1) |
225 |
|
(subtypep* t1 t2) |
226 |
|
(multiple-value-bind (sub2 success2) |
227 |
|
(subtypep* `(not ,t2) `(not ,t1)) |
228 |
|
(or (not success1) |
229 |
|
(not success2) |
230 |
|
(eqlt sub1 sub2))))) |
231 |
|
|
232 |
(defun check-type-predicate (P TYPE) |
(defun check-type-predicate (P TYPE) |
233 |
"Check that a predicate P is the same as #'(lambda (x) (typep x TYPE)) |
"Check that a predicate P is the same as #'(lambda (x) (typep x TYPE)) |
234 |
by applying both to all elements of *UNIVERSE*. Print message |
by applying both to all elements of *UNIVERSE*. Print message |