lean4-htt/tests/lean/run/smt_rsimp.lean

19 lines
412 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.

constant p {α} : αα → Prop
axiom pax {α} : ∀ n : α, p n n
open tactic
meta def check_expr (p : pexpr) (t : expr) : tactic unit :=
do e ← to_expr p, guard (t = e)
meta def check_target (p : pexpr) : tactic unit :=
target >>= check_expr p
example (s t : list nat) (h : t = s) : p (s ++ []) ([] ++ t) :=
begin [smt]
add_simp_lemmas,
ematch,
rsimp,
check_target `(p s s),
apply pax
end