X-Git-Url: http://git.lukelau.me/?p=opengl.git;a=blobdiff_plain;f=src%2FLanguage%2FHaskell%2FLSP%2FTest.hs;h=bb4d05721b82b2f43110ff087a6ad7237206b1be;hp=137cbb7a329e93761f6eb792f9043954d145437d;hb=4c5ad9975b44f2a0482d98c1e67f2de78e7dd0ca;hpb=d91bb1f20e71593cf50b6225031a29e050445198 diff --git a/src/Language/Haskell/LSP/Test.hs b/src/Language/Haskell/LSP/Test.hs index 137cbb7..bb4d057 100644 --- a/src/Language/Haskell/LSP/Test.hs +++ b/src/Language/Haskell/LSP/Test.hs @@ -359,7 +359,7 @@ getDocumentSymbols doc = do -- | Returns all the code actions in a document by -- querying the code actions at each of the current -- diagnostics' positions. -getAllCodeActions :: TextDocumentIdentifier -> Session [CommandOrCodeAction] +getAllCodeActions :: TextDocumentIdentifier -> Session [CAResult] getAllCodeActions doc = do curDiags <- fromMaybe [] . Map.lookup (doc ^. uri) . curDiagnostics <$> get let ctx = CodeActionContext (List curDiags) Nothing @@ -367,7 +367,7 @@ getAllCodeActions doc = do foldM (go ctx) [] curDiags where - go :: CodeActionContext -> [CommandOrCodeAction] -> Diagnostic -> Session [CommandOrCodeAction] + go :: CodeActionContext -> [CAResult] -> Diagnostic -> Session [CAResult] go ctx acc diag = do ResponseMessage _ rspLid mRes mErr <- request TextDocumentCodeAction (CodeActionParams doc (diag ^. range) ctx)