;;
let unify a b c d = wrap (unify a b c) d;;
+let fix_sorts (name,ctx,t) =
+ let f () =
+ let t = NCicUnification.fix_sorts t in
+ name,ctx,t
+ in
+ wrap f ()
+;;
+
let refine status ctx term expty =
let status, (nt,_,term) = relocate status ctx term in
let status, ne, expty =
'status * cic_term * cic_term (* status, term, type *)
val apply_subst:
#pstatus as 'status -> NCic.context -> cic_term -> 'status * cic_term
+val fix_sorts: cic_term -> cic_term
val get_goalty: #pstatus -> int -> cic_term
val mk_meta:
let compute_goal_sort_tac = distribute_tac (fun status goal ->
let goalty = get_goalty status goal in
let status, goalsort = typeof status (ctx_of goalty) goalty in
+ let goalsort = fix_sorts goalsort in
sort := Some goalsort;
exec id_tac status goal)
in
| _ -> assert false
in
let name =
- match dir with `LeftToRight -> "eq_elim_r" | `RightToLeft -> "eq" ^ suffix
+ match dir with
+ `LeftToRight -> "eq" ^ suffix ^ "_r"
+ | `RightToLeft -> "eq" ^ suffix
in
block_tac
[ select_tac ~where ~job:(`Substexpand 1) true;