X-Git-Url: http://git.lukelau.me/?a=blobdiff_plain;f=example%2FMain.hs;h=4891c6c12219cf34d85b1b23bb1a303cbb17bd6f;hb=22df37c703e39fa5ebeb130be5785b3a9713c520;hp=d66e17e11075f0f018e7ee8a37eaf4410734212a;hpb=f1238f8db54eafbf0e3352140818875ad4cfd997;p=opengl.git diff --git a/example/Main.hs b/example/Main.hs index d66e17e..4891c6c 100644 --- a/example/Main.hs +++ b/example/Main.hs @@ -1,18 +1,13 @@ import Language.Haskell.LSP.Test import Language.Haskell.LSP.TH.DataTypesJSON -import Data.Proxy import Control.Monad.IO.Class -main = runSession "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 (Proxy :: Proxy DocumentSymbolRequest) TextDocumentDocumentSymbol (DocumentSymbolParams docId) + sendRequest TextDocumentDocumentSymbol (DocumentSymbolParams docItem) skipMany loggingNotification - response >>= liftIO . print \ No newline at end of file + anyResponse >>= liftIO . print