summaryrefslogtreecommitdiff
path: root/test-suite/bugs/closed/shouldsucceed/808_2411.v
diff options
context:
space:
mode:
authorGravatar Stephane Glondu <steph@glondu.net>2012-01-07 17:59:15 +0100
committerGravatar Stephane Glondu <steph@glondu.net>2012-01-07 18:20:56 +0100
commit2ee61d5995ef572f0124691f10630305a59b4f73 (patch)
treeeaeffb7be70ce770a822108f8a527312f67fd8b2 /test-suite/bugs/closed/shouldsucceed/808_2411.v
parentba021624830c7ad5df0688d144e4305551ae1a5f (diff)
parentde109d8c0c68f569b907e6e24271f259ba28888e (diff)
Prepare upload to squeeze-backportsdebian/8.3.pl3+dfsg-1_bpo60+1
Diffstat (limited to 'test-suite/bugs/closed/shouldsucceed/808_2411.v')
-rw-r--r--test-suite/bugs/closed/shouldsucceed/808_2411.v27
1 files changed, 27 insertions, 0 deletions
diff --git a/test-suite/bugs/closed/shouldsucceed/808_2411.v b/test-suite/bugs/closed/shouldsucceed/808_2411.v
new file mode 100644
index 00000000..1c13e745
--- /dev/null
+++ b/test-suite/bugs/closed/shouldsucceed/808_2411.v
@@ -0,0 +1,27 @@
+Section test.
+Variable n:nat.
+Lemma foo: 0 <= n.
+Proof.
+(* declaring an Axiom during a proof makes it immediatly
+ usable, juste as a full Definition. *)
+Axiom bar : n = 1.
+rewrite bar.
+now apply le_S.
+Qed.
+
+Lemma foo' : 0 <= n.
+Proof.
+(* Declaring an Hypothesis during a proof is ok,
+ but this hypothesis won't be usable by the current proof(s),
+ only by later ones. *)
+Hypothesis bar' : n = 1.
+Fail rewrite bar'.
+Abort.
+
+Lemma foo'' : 0 <= n.
+Proof.
+rewrite bar'.
+now apply le_S.
+Qed.
+
+End test. \ No newline at end of file