Add "intro" to LSP, improve error locations

This commit is contained in:
2026-02-23 13:16:06 -08:00
parent 673c79b786
commit 3cc3801f4d
4 changed files with 79 additions and 21 deletions

View File

@@ -143,6 +143,11 @@ codeActionInfo uri line col = unsafePerformIO $ do
$ ("title", JsonStr "Case split")
:: ("edit", (single "changes" $ single uri $ JsonArray $ map editToJson edits))
:: Nil
actionToJson (Intro name edit) =
JsonObj
$ ("title", JsonStr "Intro \{name}")
:: ("edit", (single "changes" $ single uri $ JsonArray $ editToJson edit :: Nil))
:: Nil
actionToJson (AddMissingAction edits) =
JsonObj
$ ("title", JsonStr "Add missing cases")