Skip to content

Commit

Permalink
Update Std/Tactic/TryThis.lean
Browse files Browse the repository at this point in the history
  • Loading branch information
kim-em authored Aug 9, 2023
1 parent db96f32 commit ed72df0
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions Std/Tactic/TryThis.lean
Original file line number Diff line number Diff line change
Expand Up @@ -184,13 +184,7 @@ def addRewriteSuggestion (ref : Syntax) (rules : List (Expr × Bool))
let loc ← loc?.mapM fun loc => do `(location| at $(← delab loc):term)
`(tactic| rw [$rules_stx,*] $(loc)?)

let mut tacMsg :=
let rulesMsg := MessageData.sbracket <| MessageData.joinSep
(rules.map fun ⟨e, symm⟩ => (if symm then "← " else "") ++ m!"{e}") ", "
if let some loc := loc? then
m!"rw {rulesMsg} at {loc}"
else
m!"rw {rulesMsg}"
let mut tacMsg := m!"{tac}"
let mut extraMsg := ""
if let some type := type? then
tacMsg := tacMsg ++ m!"\n-- {type}"
Expand Down

0 comments on commit ed72df0

Please sign in to comment.