lean4-htt/tests/lean/run/newfrontend3.lean
Leonardo de Moura bb07a732e7
refactor: use mkAuxLemma in mkAuxTheorem (#7762)
cc @Kha

---------

Co-authored-by: Sebastian Ullrich <sebasti@nullri.ch>
2025-03-31 22:50:30 +00:00

33 lines
691 B
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

--
structure S :=
(g {α} : αα)
def f (h : Nat → ({α : Type} → αα) × Bool) : Nat :=
(h 0).1 1
def tst : Nat :=
f fun n => (fun x => x, true)
def ex : id (Nat → Nat) :=
by {
intro;
assumption
}
def g (i j k : Nat) (a : Array Nat) (h₁ : i < k) (h₂ : k < j) (h₃ : j < a.size) : Nat :=
let vj := a[j];
let vi := a[i];
vi + vj
set_option pp.all true in
#print g
#check g._proof_1
theorem ex1 {p q r s : Prop} : p ∧ q ∧ r ∧ s → r ∧ s ∧ q ∧ p :=
fun ⟨hp, hq, hr, hs⟩ => ⟨hr, hs, hq, hp⟩
theorem ex2 {p q r s : Prop} : p ∧ q ∧ r ∧ s → r ∧ s ∧ q ∧ p := by
intro ⟨hp, hq, hr, hs⟩
exact ⟨hr, hs, hq, hp⟩