aboutsummaryrefslogtreecommitdiff
path: root/theories/Init/DatatypesSyntax.v
diff options
context:
space:
mode:
authorherbelin2002-12-15 12:34:22 +0000
committerherbelin2002-12-15 12:34:22 +0000
commitde32f8f70ca9e077cdfc922fff59530b74a0cfa6 (patch)
tree8149a2deef4b436389f797002ab630dfb977b7f7 /theories/Init/DatatypesSyntax.v
parent356c712e811c23e496ace3684b3345972b5d8f71 (diff)
Une entrée spéciale "annot" pour les piquants
Positionnement du scope type_scope à certains endroits bien choisis git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@3445 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'theories/Init/DatatypesSyntax.v')
-rw-r--r--theories/Init/DatatypesSyntax.v16
1 files changed, 11 insertions, 5 deletions
diff --git a/theories/Init/DatatypesSyntax.v b/theories/Init/DatatypesSyntax.v
index 52e1328b56..06f28b503a 100644
--- a/theories/Init/DatatypesSyntax.v
+++ b/theories/Init/DatatypesSyntax.v
@@ -12,15 +12,21 @@ Require Export Datatypes.
(** Symbolic notations for things in [Datatypes.v] *)
-Infix LEFTA 4 "+" sum : type_scope.
-Infix RIGHTA 3 "*" prod : type_scope.
+Arguments Scope sum [type_scope type_scope].
+Arguments Scope prod [type_scope type_scope].
+
+Infix "+" sum (at level 4, left associativity) : type_scope.
+Infix "*" prod (at level 3, right associativity) : type_scope.
+
Notation "( x , y )" := (pair ? ? x y) (at level 0).
Notation Fst := (fst ? ?).
Notation Snd := (snd ? ?).
+Arguments Scope option [ type_scope ].
+
(** Parsing only of things in [Datatypes.v] *)
-Notation "< A , B > ( x , y )" := (pair A B x y) (at level 1, only parsing).
-Notation "< A , B > 'Fst' ( p )" := (fst A B p) (at level 1, only parsing).
-Notation "< A , B > 'Snd' ( p )" := (snd A B p) (at level 1, only parsing).
+Notation "< A , B > ( x , y )" := (pair A B x y) (at level 1, only parsing, A annot).
+Notation "< A , B > 'Fst' ( p )" := (fst A B p) (at level 1, only parsing, A annot).
+Notation "< A , B > 'Snd' ( p )" := (snd A B p) (at level 1, only parsing, A annot).