Skip to content

Commit

Permalink
fix: monads
Browse files Browse the repository at this point in the history
  • Loading branch information
digama0 committed Oct 24, 2023
1 parent 1e81fc9 commit 0d39f21
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Std/Tactic/TryThis.lean
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ The parameters are:
* `header`: a string that begins the display. By default, it is `"Try this: "`.
-/
def addSuggestion (ref : Syntax) (s : Suggestion) (origSpan? : Option Syntax := none)
(header : String := "Try this: ") : CoreM Unit := do
(header : String := "Try this: ") : MetaM Unit := do
logInfoAt ref m!"{header}{s}"
addSuggestionCore ref #[s] header (isInline := true) origSpan?

Expand Down Expand Up @@ -385,7 +385,7 @@ The parameters are:
-/
def addSuggestions (ref : Syntax) (suggestions : Array Suggestion)
(origSpan? : Option Syntax := none) (header : String := "Try these:")
(style? : Option SuggestionStyle := none) : CoreM Unit := do
(style? : Option SuggestionStyle := none) : MetaM Unit := do
if suggestions.isEmpty then throwErrorAt ref "no suggestions available"
let msgs := suggestions.map toMessageData
let msgs := msgs.foldl (init := MessageData.nil) (fun msg m => msg ++ m!"\n• " ++ m)
Expand Down

0 comments on commit 0d39f21

Please sign in to comment.