@ names in
let outtype = pp rels outtype in
let outtype= CicNotationPt.Binder (`Lambda, (arg, Some arg_ty), outtype) in
- CicNotationPt.Binder
- (`Lambda, (arg,Some arg_ty),
- CicNotationPt.Case (arg,None,Some outtype,[branch]))
+ [arg, Some arg_ty], CicNotationPt.Case (arg,None,Some outtype,[branch])
| _,NCic.Prod (name,_,t) ->
let name = mk_id name in
- CicNotationPt.Binder
- (`Lambda, (name,None), aux (name::names) t (leftno - 1))
+ let params,body = aux (name::names) t (leftno - 1) in
+ (name,None)::params, body
| _,_ -> assert false
in
- let res = aux [] consty leftno in
+ let params,bo = aux [] consty leftno in
+ let pprojname = mk_id projname in
+ let res =
+ CicNotationPt.LetRec (`Inductive,
+ [params, (pprojname,None), bo, leftno], pprojname) in
(* prerr_endline
(BoxPp.render_to_string
~map_unicode_to_tex:false
#A; #B; napply mk_setoid;
##[ napply (function_space A B);
##| #f; #f1; napply (∀a:A. proofs (eq … (f a) (f1 a)));
-##| nwhd; #x; #a;
- napply (f_ok … x); (* QUI!! *)
-(* unfold carr; unfold proofs; simplify;
- apply (refl A)
- | simplify;
- intros;
- unfold carr; unfold proofs; simplify;
- apply (sym B);
- apply (f a)
- | simplify;
- intros;
- unfold carr; unfold proofs; simplify;
- apply (trans B ? (y a));
- [ apply (f a)
- | apply (f1 a)]]
-qed.
+##| nnormalize; #x; #a; napply (f_ok … x); napply refl
+ | nnormalize; #x; #y; #H; #a; napply sym; napply H
+ | nnormalize; #z; #x; #y; #H1; #H2; #a;
+ napply trans; ##[##2: napply H1 | ##skip | napply H2]##]
+nqed.
nrecord isomorphism (A,B: setoid): Type ≝
{ map1:> function_space_setoid A B;