coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Jacques-Henri Jourdan <jacques-henri.jourdan AT inria.fr>
- To: coq-club AT inria.fr
- Subject: [Coq-Club] Fixpoint definition
- Date: Mon, 15 Jul 2013 17:13:49 +0200
Hi coqclub,
If I define a list this way (I have some reasonnably good reason not to currify the constructor here):
Inductive lst :=
| Nil | Cons : nat*lst -> lst.
I can do some fixpoint computation this way :
Fixpoint test l :=
match l with
| Nil => 0
| Cons (t, q) =>
test q
end.
However, the termination checker fails on this similar test case:
Fixpoint test2 p :=
match p with
| (_, Nil) => 0
| (_, Cons l) =>
test l
end.
Do you have any idea why ? Is there a common workaround (other than using the other formulation above, that would lead to a lot of code duplication in my case) ?
Thanks,
--
Jacques-Henri Jourdan
- [Coq-Club] Fixpoint definition, Jacques-Henri Jourdan, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Pierre Casteran, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Michiel Helvensteijn, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Jacques-Henri Jourdan, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Michiel Helvensteijn, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Jacques-Henri Jourdan, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Michiel Helvensteijn, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Michiel Helvensteijn, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Jacques-Henri Jourdan, 07/16/2013
- Re: [Coq-Club] Fixpoint definition, Jacques-Henri Jourdan, 07/16/2013
- Re: [Coq-Club] Fixpoint definition, Michiel Helvensteijn, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Daniel Schepler, 07/16/2013
- Re: [Coq-Club] Fixpoint definition, Michiel Helvensteijn, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Jacques-Henri Jourdan, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Michiel Helvensteijn, 07/15/2013
- Re: [Coq-Club] Fixpoint definition, Pierre Casteran, 07/15/2013
Archive powered by MHonArc 2.6.18.