X-Git-Url: http://git.lukelau.me/?a=blobdiff_plain;f=example%2FMain.hs;h=29795fa22e52b76279d1ae98eca5c5f111eb72cd;hb=5170a20560a68b8fcaed83ecaf6146d84a147992;hp=5aaa2d13abee6adb516dcfece381e3cd215d1e50;hpb=df782ad008b840c0860173821226542e2e70f2e9;p=opengl.git diff --git a/example/Main.hs b/example/Main.hs index 5aaa2d1..29795fa 100644 --- a/example/Main.hs +++ b/example/Main.hs @@ -4,14 +4,15 @@ import Data.Proxy import Control.Monad.IO.Class -main = runSession "test/recordings/renamePass" $ do +main = runSession "hie --lsp" "test/recordings/renamePass" $ do 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 docId) - syms <- getMessage :: Session DocumentSymbolsResponse - liftIO $ print syms \ No newline at end of file + skipMany loggingNotification + + anyResponse >>= liftIO . print