is_really_smaller r_uri r_len ~subst ~metasenv (shift_k (name,C.Decl s) k) t
| C.Appl (he::_) ->
is_really_smaller r_uri r_len ~subst ~metasenv k he
- | C.Rel _
- | C.Const (Ref.Ref (_,Ref.Con _)) -> false
- | C.Appl []
- | C.Const (Ref.Ref (_,Ref.Fix _)) -> assert false
+ | C.Appl [] | C.Implicit _ -> assert false
| C.Meta _ -> true
| C.Match (Ref.Ref (_,Ref.Ind (isinductive,_,_)),_,term,pl) ->
(match term with
is_really_smaller r_uri r_len ~subst ~metasenv k e)
pl dcl
| _ -> List.for_all (is_really_smaller r_uri r_len ~subst ~metasenv k) pl)
- | _ -> assert false
+ | _ -> false
and returns_a_coinductive ~subst context ty =
match R.whd ~subst context ty with
--- /dev/null
+(**************************************************************************)
+(* ___ *)
+(* ||M|| *)
+(* ||A|| A project by Andrea Asperti *)
+(* ||T|| *)
+(* ||I|| Developers: *)
+(* ||T|| The HELM team. *)
+(* ||A|| http://helm.cs.unibo.it *)
+(* \ / *)
+(* \ / This file is distributed under the terms of the *)
+(* v GNU General Public License Version 2 *)
+(* *)
+(**************************************************************************)
+
+include "logic/pts.ma".
+
+include "nat/minus.ma".
+
+ninductive D: nat → Prop ≝
+ D0: D O
+ | Dn: ∀n. D (n - 2) → D n.
+
+naxiom dow: ∀n,m.∀p: D n. n = S m → False.
+naxiom destr: ∀n. O = S n → False.
+
+nlet rec f (n:nat) (p:D n) on p : nat ≝
+ match n return λm. n=m → nat with
+ [ O ⇒ λ_.O
+ | S m ⇒ λH. f (n - 2) ?] (refl_eq ? n).
+ ncases p in H
+ [ #K; ncases (destr ? K)
+ | #n0; #p; #H; nassumption ]
+nqed.
\ No newline at end of file