-
Notifications
You must be signed in to change notification settings - Fork 30
/
Copy pathEraseUnfold.lean
43 lines (32 loc) · 957 Bytes
/
EraseUnfold.lean
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/-
Copyright (c) 2023 Jannis Limperg. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jireh Loreaux, Jannis Limperg
-/
-- Thanks to Jireh Loreaux for reporting this MWE.
import Aesop
set_option aesop.check.all true
set_option aesop.smallErrorMessages true
@[irreducible]
def foo : Nat := 37
/--
error: tactic 'aesop' failed, failed to prove the goal after exhaustive search.
-/
#guard_msgs in
example : foo = 37 := by
aesop (config := { terminal := true }) (erase Aesop.BuiltinRules.rfl)
example : foo = 37 := by
unfold foo
rfl
attribute [aesop norm unfold] foo
example : foo = 37 := by aesop (erase Aesop.BuiltinRules.rfl)
attribute [-aesop] foo
/--
error: tactic 'aesop' failed, failed to prove the goal after exhaustive search.
-/
#guard_msgs in
example : foo = 37 := by
aesop (config := { terminal := true }) (erase Aesop.BuiltinRules.rfl)
example : foo = 37 := by
unfold foo
rfl