coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Daniel Schepler <dschepler AT gmail.com>
- To: Coq Club <coq-club AT inria.fr>
- Subject: Re: [Coq-Club] Questions about two theorems
- Date: Tue, 16 Sep 2014 08:21:23 -0700
On Tue, Sep 16, 2014 at 2:11 AM, Cedric Auger
<sedrikov AT gmail.com>
wrote:
> Yes, that is clever.
> By the way, I do not know why people use this definition of "fin" which I
> find rather inconvenient.
>
> Inductive emptySet : Type := .
>
> Fixpoint fin2 (n : nat) : Type := match n with O => emptySet | S n => option
> (fin2 n) end.
>
> is a lot more convenient from my point of view.
> Here, we do not have to do all these inversion stuff when inspecting an
> element.
I've often found that inductive versions have nicer extractions to
OCaml than the corresponding Fixpoint to Type or Set definitions whose
extractions require a lot of Obj.magic.
--
Daniel Schepler
- [Coq-Club] Questions about two theorems, John Wiegley, 09/15/2014
- Re: [Coq-Club] Questions about two theorems, Daniel Schepler, 09/15/2014
- Re: [Coq-Club] Questions about two theorems, Cedric Auger, 09/15/2014
- Re: [Coq-Club] Questions about two theorems, John Wiegley, 09/15/2014
- Re: [Coq-Club] Questions about two theorems, Daniel Schepler, 09/15/2014
- Re: [Coq-Club] Questions about two theorems, John Wiegley, 09/15/2014
- Re: [Coq-Club] Questions about two theorems, Cedric Auger, 09/16/2014
- Re: [Coq-Club] Questions about two theorems, Thorsten Altenkirch, 09/16/2014
- Re: [Coq-Club] Questions about two theorems, Cedric Auger, 09/16/2014
- Re: [Coq-Club] Questions about two theorems, flicky frans, 09/16/2014
- Re: [Coq-Club] Questions about two theorems, Daniel Schepler, 09/16/2014
- Re: [Coq-Club] Questions about two theorems, Cedric Auger, 09/16/2014
- Re: [Coq-Club] Questions about two theorems, Thorsten Altenkirch, 09/16/2014
- Re: [Coq-Club] Questions about two theorems, Cedric Auger, 09/15/2014
- Re: [Coq-Club] Questions about two theorems, flicky frans, 09/15/2014
- Re: [Coq-Club] Questions about two theorems, Daniel Schepler, 09/15/2014
- Re: [Coq-Club] Questions about two theorems, John Wiegley, 09/15/2014
Archive powered by MHonArc 2.6.18.