test(tests/lean/run): add additional tests for section parameter/variable and strict implicit argument
This commit is contained in:
parent
bf01cfeec5
commit
7073f036d8
1 changed files with 27 additions and 0 deletions
27
tests/lean/run/sec_var.lean
Normal file
27
tests/lean/run/sec_var.lean
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
import logic
|
||||||
|
|
||||||
|
section
|
||||||
|
parameter A : Type
|
||||||
|
definition foo : ∀ ⦃ a b : A ⦄, a = b → a = b :=
|
||||||
|
take a b H, H
|
||||||
|
|
||||||
|
variable a : A
|
||||||
|
set_option pp.implicit true
|
||||||
|
check foo (eq.refl a)
|
||||||
|
check foo
|
||||||
|
check foo = (λ (a b : A) (H : a = b), H)
|
||||||
|
end
|
||||||
|
|
||||||
|
check foo = (λ (A : Type) (a b : A) (H : a = b), H)
|
||||||
|
|
||||||
|
section
|
||||||
|
variable A : Type
|
||||||
|
definition foo2 : ∀ ⦃ a b : A ⦄, a = b → a = b :=
|
||||||
|
take a b H, H
|
||||||
|
|
||||||
|
variable a : A
|
||||||
|
set_option pp.implicit true
|
||||||
|
check foo2 A (eq.refl a)
|
||||||
|
check foo2
|
||||||
|
check foo2 A = (λ (a b : A) (H : a = b), H)
|
||||||
|
end
|
Loading…
Add table
Reference in a new issue