The easy case is when the outype is specified, that amount
to a trivial check. Otherwise, we should guess a type from
its instances *)
+
(* easy case *)
let _, subst, metasenv =
type_of_aux subst metasenv context
(match hetype with
Cic.Prod (n,s,t) ->
let subst,metasenv =
- fo_unif_subst subst context metasenv s hety
+ fo_unif_subst subst context metasenv hety s
in
eat_prods metasenv subst context
(CicMetaSubst.subst subst hete t) tl
eat_prods metasenv subst context hetype' tlbody_and_type
in
t,subst,metasenv
-
(*
let rec aux context' args (resty,subst,metasenv) =
function
in
aux [] [] (hetype,subst,metasenv) tlbody_and_type
*)
-
in
let ty,subst',metasenv' =
type_of_aux [] metasenv context t