coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Jacek Chrzaszcz <chrzaszc AT mimuw.edu.pl>
- To: Pierre Casteran <casteran AT labri.fr>
- Subject: Re: [Coq-Club] problem with notations
- Date: Tue, 13 Jan 2004 16:51:27 +0100
- List-archive: <http://pauillac.inria.fr/pipermail/coq-club/>
- Resent-date: Tue, 13 Jan 2004 16:55:03 +0100
- Resent-from: chrzaszc AT mimuw.edu.pl
- Resent-message-id: <200401131555.i0DFt3F30645 AT absurd.mimuw.edu.pl>
- Resent-to: coq-club AT pauillac.inria.fr
On Tue, Jan 13, 2004 at 02:00:16PM +0100, Pierre Casteran wrote:
>
> There is a slight problem. This work only if we work with opaque
> signature constraint , and not if I use '<:'
>
Yes. That is also a feature ;)
The "<:" transparent signature constraint is only there to make sure that
the module has the right signature (and for documentation).
It changes nothing for typing and "extra-logical" stuff like notations etc.
One might of course try to use the notations included in the signature, but
then another problem arises. What about:
Module Type S1.
Inductive P : Set :=
c : P.
Notation "'XXXXXXXXXXXXXXXX'" := c (at level 40) : my_scope.
End S1.
Module M1 <: S1.
Inductive P : Set :=
c : P .
Notation "'X'" := c (at level 40) : my_scope.
End M1.
Import M1.
Open Scope my_scope.
Print c.
(*
Now what: XXXXXXXXXXXXXXX or X ?
*)
>
> By the way, I have often to deal with inductive type definitions.
> Is it OK to put the inductive definition in the signature (since
> it is a declaration of the constructors and the _ind, _rec, ...
> theorems), and duplicate the inductive definition in the signature
> and in the module and/or functor ?.
>
Yes, it is OK. Apart from having to write everything twice (and making Coq
verify that the declaration and definitions correspond) I can see no
problem.
BTW: I am thinking about implementing some "Include from signature"
command but I am not sure what it will precisely be and (even less) when
this will be available.
> Pierre
>
> P.S.
> Jacek, Igor (Walukiewicz) told me about your thesis. Congratulations !
>
Thank you very much!
Jacek
PS. I hope I will have some time to hack at last!
- [Coq-Club] problem with notations, Houda Anoun
- Re: [Coq-Club] problem with notations,
Jacek Chrzaszcz
- Re: [Coq-Club] problem with notations,
Pierre Casteran
- Re: [Coq-Club] problem with notations, Jacek Chrzaszcz
- Re: [Coq-Club] problem with notations,
Houda Anoun
- Re: [Coq-Club] problem with notations, Jacek Chrzaszcz
- Re: [Coq-Club] problem with notations,
Pierre Casteran
- <Possible follow-ups>
- Re: [Coq-Club] problem with notations,
Jevgenijs Sallinens
- Re: [Coq-Club] problem with notations, Pierre Courtieu
- Re: [Coq-Club] problem with notations, Houda Anoun
- Re: [Coq-Club] problem with notations,
Jevgenijs Sallinens
- Re: [Coq-Club] problem with notations, Pierre Casteran
- Re: [Coq-Club] problem with notations, Jacek Chrzaszcz
- Re: [Coq-Club] problem with notations, Jevgenijs Sallinens
- Re: [Coq-Club] problem with notations, Jevgenijs Sallinens
- Re: [Coq-Club] problem with notations,
Jacek Chrzaszcz
Archive powered by MhonArc 2.6.16.