test(tests/lean/unfold_rec2): add example from #692
This commit is contained in:
parent
98cace9bf8
commit
f0e3eef38a
2 changed files with 13 additions and 0 deletions
10
tests/lean/unfold_rec2.lean
Normal file
10
tests/lean/unfold_rec2.lean
Normal file
|
@ -0,0 +1,10 @@
|
|||
open nat
|
||||
|
||||
definition f (a n : ℕ) : ℕ := nat.rec_on n (λa', a') (λn' f' a', f' (a' * 2)) a
|
||||
|
||||
example (a n : nat) : a = 2 → f a (succ n) = f 4 n :=
|
||||
begin
|
||||
unfold f at {1},
|
||||
state,
|
||||
intros, subst a
|
||||
end
|
3
tests/lean/unfold_rec2.lean.expected.out
Normal file
3
tests/lean/unfold_rec2.lean.expected.out
Normal file
|
@ -0,0 +1,3 @@
|
|||
unfold_rec2.lean:8:2: proof state
|
||||
a n : ℕ
|
||||
⊢ a = 2 → f (a * 2) n = f 4 n
|
Loading…
Reference in a new issue