From 7ae84753e8e516c589751aeafa7a080c144cec88 Mon Sep 17 00:00:00 2001 From: Juan Jose Garcia Ripoll Date: Sun, 30 Nov 2008 23:15:39 +0100 Subject: [PATCH] An type with an unsupported CONS type cannot be replaced by just CONS. Use T instead for type estimates in TYPE-AND/OR --- src/cmp/cmptype.lsp | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/src/cmp/cmptype.lsp b/src/cmp/cmptype.lsp index 7dfba46b7..5d6512ef4 100644 --- a/src/cmp/cmptype.lsp +++ b/src/cmp/cmptype.lsp @@ -144,9 +144,11 @@ (t `(AND ,t1 ,t2)))) ((eq tag1 'CONS) - (type-and 'CONS t2)) + (cmpwarn "Unsupported CONS type ~S. Replacing it with T." t1) + t2) ((eq tag2 'CONS) - (type-and t1 'CONS)) + (cmpwarn "Unsupported CONS type ~S. Replacing it with T." t2) + t1) ((null tag1) (cmpwarn "Unknown type ~S. Assuming it is T." t1) t2) @@ -176,15 +178,17 @@ (t `(OR ,t1 ,t2)))) ((eq tag1 'CONS) - (type-or 'CONS t2)) + (cmpwarn "Unsupported CONS type ~S. Replacing it with T." t1) + T) ((eq tag2 'CONS) - (type-or t1 'CONS)) + (cmpwarn "Unsupported CONS type ~S. Replacing it with T." t2) + T) ((null tag1) (cmpwarn "Unknown type ~S" t1) - 'T) + T) (t (cmpwarn "Unknown type ~S" t2) - 'T)))) + T)))) (defun type>= (type1 type2) (subtypep type2 type1))