aboutsummaryrefslogtreecommitdiff
path: root/test-suite
diff options
context:
space:
mode:
authorherbelin2011-03-31 18:58:17 +0000
committerherbelin2011-03-31 18:58:17 +0000
commit7d497e25f19022aa7f697cffb353f9f6776e822e (patch)
tree38d7597fa7d2399ca0b56950756d712c61b6c3f5 /test-suite
parent3aad12391a9566af41395c674614e56383dff8c2 (diff)
Did that adding a rule for printing applications as "f(x)" works.
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@13946 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'test-suite')
-rw-r--r--test-suite/output/Notations2.out2
-rw-r--r--test-suite/output/Notations2.v5
2 files changed, 7 insertions, 0 deletions
diff --git a/test-suite/output/Notations2.out b/test-suite/output/Notations2.out
index 6731d5054e..444d6b0910 100644
--- a/test-suite/output/Notations2.out
+++ b/test-suite/output/Notations2.out
@@ -25,3 +25,5 @@ let '(a, _, _) := (2, 3, 4) in a
Defining 'let'' as keyword
let' f (x y z : nat) (_ : bool) := x + y + z + 1 in f 0 1 2
: bool -> nat
+λ (f : nat -> nat) (x : nat), f(x) + S(x)
+ : (nat -> nat) -> nat -> nat
diff --git a/test-suite/output/Notations2.v b/test-suite/output/Notations2.v
index a78088bad5..e7b0b97546 100644
--- a/test-suite/output/Notations2.v
+++ b/test-suite/output/Notations2.v
@@ -55,6 +55,11 @@ Notation "'let'' f x .. y := t 'in' u":=
Check let' f x y z (a:bool) := x+y+z+1 in f 0 1 2.
+(* In practice, only the printing rule is used here *)
+(* Note: does not work for pattern *)
+Notation "f ( x )" := (f x) (at level 10, format "f ( x )").
+Check fun f x => f x + S x.
+
(* This one is not fully satisfactory because binders in the same type
are re-factorized and parentheses are needed even for atomic binder