X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fcomponents%2Fcic_proof_checking%2FcicUnivUtils.ml;h=2c35ebe1a05badb17fd5269edfa4411662bb5c2e;hb=13bfd154ade0996d34e7e723398ac7ab76a51717;hp=cbc87e98afcc3574042a3b2813749a7bd14dd888;hpb=db48e1ca9a2c0db7e8101367ec98e4ff2f1c069c;p=helm.git diff --git a/helm/software/components/cic_proof_checking/cicUnivUtils.ml b/helm/software/components/cic_proof_checking/cicUnivUtils.ml index cbc87e98a..2c35ebe1a 100644 --- a/helm/software/components/cic_proof_checking/cicUnivUtils.ml +++ b/helm/software/components/cic_proof_checking/cicUnivUtils.ml @@ -79,13 +79,15 @@ let universes_of_obj uri t = | C.Meta (n,l1) -> C.Meta (n, List.map (HExtlib.map_option aux) l1) | C.Sort (C.Type i) -> add_result [i]; C.Sort (C.Type (CicUniv.name_universe i uri)) + | C.Sort (C.CProp i) -> add_result [i]; + C.Sort (C.CProp (CicUniv.name_universe i uri)) | C.Rel _ | C.Sort _ | C.Implicit _ as x -> x | C.Cast (v,t) -> C.Cast (aux v, aux t) | C.Prod (b,s,t) -> C.Prod (b,aux s, aux t) | C.Lambda (b,s,t) -> C.Lambda (b,aux s, aux t) - | C.LetIn (b,s,t) -> C.LetIn (b,aux s, aux t) + | C.LetIn (b,s,ty,t) -> C.LetIn (b,aux s, aux ty, aux t) | C.Appl li -> C.Appl (List.map aux li) | C.MutCase (uri,n1,ty,te,patterns) -> C.MutCase (uri,n1,aux ty,aux te, List.map aux patterns) @@ -123,14 +125,8 @@ let universes_of_obj uri t = let o = aux_obj t in List.flatten !results, o -let rec list_uniq = function - | [] -> [] - | h::[] -> [h] - | h1::h2::tl when CicUniv.eq h1 h2 -> list_uniq (h2 :: tl) - | h1::tl (* when h1 <> h2 *) -> h1 :: list_uniq tl - let list_uniq l = - list_uniq (List.fast_sort CicUniv.compare l) + HExtlib.list_uniq (List.fast_sort CicUniv.compare l) let clean_and_fill uri obj ugraph = (* universes of obj fills the universes of the obj with the right uri *)