From: Enrico Tassi Date: Fri, 14 Apr 2006 10:11:32 +0000 (+0000) Subject: added minimal euristic for generic terms carrier comparison X-Git-Tag: make_still_working~7407 X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=commitdiff_plain;h=9ff32d2a3efcf850ea52fe0223a5152f8777aee5;p=helm.git added minimal euristic for generic terms carrier comparison --- diff --git a/helm/software/components/library/coercDb.ml b/helm/software/components/library/coercDb.ml index c5356b3e1..8b7982ea0 100644 --- a/helm/software/components/library/coercDb.ml +++ b/helm/software/components/library/coercDb.ml @@ -59,12 +59,14 @@ let eq_carr src tgt = | Sort (Cic.Type _), Sort (Cic.Type _) -> true | Sort src, Sort tgt when src = tgt -> true | Term t1, Term t2 -> - if CicUtil.is_meta_closed t1 && CicUtil.is_meta_closed t2 then - raise - (EqCarrNotImplemented + if t1 = t2 then true + else + if CicUtil.is_meta_closed t1 && CicUtil.is_meta_closed t2 then + raise + (EqCarrNotImplemented (lazy ("Unsupported carr for coercions: " ^ - CicPp.ppterm t1 ^ " or " ^ CicPp.ppterm t2))) - else raise EqCarrOnNonMetaClosed + CicPp.ppterm t1 ^ " or " ^ CicPp.ppterm t2))) + else raise EqCarrOnNonMetaClosed | _, _ -> false let to_list () =