lean4-htt/tests/lean/set_attr1.lean
Leonardo de Moura 76eed7cb41 chore(library/init/meta): add to_unfold parameter to simplify, and remove redundant simp* tactics
Remark: the `to_unfold` has not been implemented yet.
2017-07-02 15:26:06 -07:00

16 lines
395 B
Text

open tactic
constant f : nat → nat
constant foo : ∀ n, f n = n + 1
constant addz : ∀ n, n + 0 = n
definition ex1 (n : nat) : f n + 0 = n + 1 :=
by do
set_basic_attribute `simp `foo ff,
set_basic_attribute `simp `addz ff,
`[simp]
definition ex2 (n : nat) : f n + 0 = n + 1 :=
by do
unset_attribute `simp `foo,
`[simp] -- should fail since we remove [simp] attribute from `foo`