X-Git-Url: http://git.lukelau.me/?a=blobdiff_plain;f=example%2FMain.hs;h=cc74026531ead6183d384d9113fd001a8f60e510;hb=d8e460543b7cbc32550bed20d20ef4b13d6705a5;hp=fc453db39cdb032a98cb0c468e697167816458cf;hpb=bc52b000bf018360efbfa0fcd289329c70d2c77e;p=opengl.git diff --git a/example/Main.hs b/example/Main.hs index fc453db..cc74026 100644 --- a/example/Main.hs +++ b/example/Main.hs @@ -1,17 +1,13 @@ import Language.Haskell.LSP.Test import Language.Haskell.LSP.TH.DataTypesJSON -import Data.Proxy import Control.Monad.IO.Class -main = runSession "hie" "test/recordings/renamePass" $ do +main = runSession "hie --lsp" "test/recordings/renamePass" $ do + docItem <- openDoc "Desktop/simple.hs" "haskell" - docItem <- getDocItem "Desktop/simple.hs" "haskell" - docId <- TextDocumentIdentifier <$> getDocUri "Desktop/simple.hs" - - sendNotification TextDocumentDidOpen (DidOpenTextDocumentParams docItem) - - sendRequest TextDocumentDocumentSymbol (DocumentSymbolParams docId) + let params = DocumentSymbolParams docItem + _ <- sendRequest TextDocumentDocumentSymbol params :: Session DocumentSymbolsResponse skipMany loggingNotification