symm tactic #
This implements the symm tactic, which can apply symmetry theorems to either the goal or a
hypothesis.
Environment extensions for symm lemmas
Return the symmetry lemmas that match the target type.
Equations
- ((rel.app arg).app arg_1).getSymmLems = do let __do_lift ← Lean.getEnv (Lean.ScopedEnvExtension.getState Lean.Meta.Symm.symmExt __do_lift).getMatch rel
- tgt.getSymmLems = Lean.throwError (Lean.toMessageData "Symmetry lemmas only apply to binary relations, not" ++ Lean.toMessageData (Lean.indentExpr tgt))
Instances For
Use a symmetry lemma (i.e. marked with @[symm]) to replace a hypothesis in a goal.
Equations
- Lean.MVarId.applySymmAt h g = do let h' ← (Lean.Expr.fvar h).applySymm let __do_lift ← g.replace h h' pure __do_lift.mvarId