(TypeCheckerFailure
(lazy (Printf.sprintf
("Appl: wrong application of %s: the parameter %s has type"^^
- "\n%s\nbut is should have type \n%s\n")
+ "\n%s\nbut it should have type \n%s\n")
(NCicPp.ppterm ~subst ~metasenv ~context he)
(NCicPp.ppterm ~subst ~metasenv ~context arg)
(NCicPp.ppterm ~subst ~metasenv ~context ty_arg)
List.iter (fun (_,_,x,_) -> ignore (typeof ~subst ~metasenv [] x)) tyl;
(* let's check if the types of the inductive constructors are well formed. *)
let len = List.length tyl in
- let tys = List.map (fun (_,n,ty,_) -> (n,(C.Decl ty))) tyl in
+ let tys = List.rev (List.map (fun (_,n,ty,_) -> (n,(C.Decl ty))) tyl) in
ignore
(List.fold_right
(fun (_,_,_,cl) i ->