We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d6cd738 commit 4c44f4eCopy full SHA for 4c44f4e
tests/lean/run/9363.lean
@@ -0,0 +1,44 @@
1
+import Std.Tactic.Do
2
+
3
+open Std.Do
4
5
+set_option mvcgen.warning false
6
7
+axiom P : Nat → Prop
8
+axiom P' : Nat → Prop
9
+axiom Q : Nat → Prop
10
+axiom R : Assertion ps
11
12
+axiom hPQ : ∀ n, P n → P' n → Q n
13
14
+axiom G : StateM Nat Unit
15
+axiom H : StateM Nat Unit
16
17
+noncomputable def F : StateM Nat Unit := do
18
+ G
19
+ H
20
21
+@[spec]
22
+axiom G_spec : ⦃⌜True⌝⦄ G ⦃⇓ _ n => ⌜P n ∧ P' n⌝⦄
23
24
25
+axiom H_spec : ⦃fun n => ⌜Q n⌝⦄ H ⦃⇓ _ => R⦄
26
27
+theorem F_spec :
28
+ ⦃⌜True⌝⦄
29
+ F
30
+ ⦃⇓ _ => R⦄ := by
31
+ mvcgen [F]
32
33
+ -- Goal:
34
+ -- s✝¹ : Nat
35
+ -- r✝ : Unit
36
+ -- s✝ : Nat
37
+ -- h : P s✝ ∧ P' s✝
38
+ -- ⊢ Q s✝
39
40
+ rename_i h
41
+ cases h
42
+ apply hPQ
43
+ assumption
44
0 commit comments