lean4-htt/tests/lean/run/1815.lean
Joachim Breitner da2b91558e
feat: improve simp trace formatting (#6951)
This PR adds line breaks and indentations to simp's trace messages to
make them easier to read (IMHO).
2025-02-04 15:47:01 +00:00

20 lines
643 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.

variable {α : Type _} [Mul α] [Inhabited α]
abbrev Left (a : α) : α := a * default
abbrev Right (a : α): α := default * a
theorem mul_comm (a b : α) : a * b = b * a := sorry
set_option trace.Meta.Tactic.simp true
/--
info: [Meta.Tactic.simp.rewrite] mul_comm:1000:perm, perm rejected Left a ==> default * a
[Meta.Tactic.simp.rewrite] mul_comm:1000:perm:
Right a
==>
a * default
[Meta.Tactic.simp.rewrite] mul_comm:1000:perm, perm rejected a * default ==> default * a
[Meta.Tactic.simp.rewrite] eq_self:1000: Left a = a * default ==> True
-/
#guard_msgs in
example (a : α) : Left a = Right a := by
simp [mul_comm]