on master help sign in
Upgrade to new haskell-lsp release (#203)
commitbc32a2eab3a73f96bd66591f742affcd395fb325 authorMoritz Kiefer <moritz.kiefer@purelyfunctional.org> dateMon 18 Nov 2019, 09:37 (7 years ago) parent133991b
7 files changed+20−19
src/Development/IDE/Core/FileStore.hs+2−2 src/Development/IDE/LSP/LanguageServer.hs+1−1 stack-ghc-lib.yaml+3−3 stack.yaml+3−3 stack84.yaml+3−3 stack88.yaml+3−2 test/exe/Main.hs+5−5
src/Development/IDE/Core/FileStore.hs+2−2
@@ -76,7 +76,7 @@ makeVFSHandle = do
7676 modifyVar_ vfsVar $ \(nextVersion, vfs) -> pure $ (nextVersion + 1, ) $
7777 case content of
7878 Nothing -> Map.delete uri vfs
79− Just content -> Map.insert uri (VirtualFile nextVersion (Rope.fromText content) Nothing) vfs
79+ Just content -> Map.insert uri (VirtualFile nextVersion (Rope.fromText content)) vfs
8080 }
8181
8282makeLSPVFSHandle :: LspFuncs c -> VFSHandle
@@ -139,7 +139,7 @@ getModificationTimeRule vfs =
139139 alwaysRerun
140140 mbVirtual <- liftIO $ getVirtualFile vfs $ filePathToUri' file
141141 case mbVirtual of
142− Just (VirtualFile ver _ _) -> pure (Just $ BS.pack $ show ver, ([], Just $ VFSVersion ver))
142+ Just (VirtualFile ver _) -> pure (Just $ BS.pack $ show ver, ([], Just $ VFSVersion ver))
143143 Nothing -> liftIO $ fmap wrap (getModTime file')
144144 `catch` \(e :: IOException) -> do
145145 let err | isDoesNotExistError e = "File does not exist: " ++ file'
src/Development/IDE/LSP/LanguageServer.hs+1−1
@@ -182,7 +182,7 @@ data Message
182182
183183modifyOptions :: LSP.Options -> LSP.Options
184184modifyOptions x = x{ LSP.textDocumentSync = Just $ tweakTDS origTDS
185− , LSP.codeActionProvider = Just $ CodeActionOptionsStatic True }
185+ }
186186 where
187187 tweakTDS tds = tds{_openClose=Just True, _change=Just TdSyncIncremental, _save=Just $ SaveOptions Nothing}
188188 origTDS = fromMaybe tdsDefault $ LSP.textDocumentSync x
stack-ghc-lib.yaml+3−3
@@ -2,9 +2,9 @@ resolver: nightly-2019-09-16
22packages:
33- .
44extra-deps:
5−- haskell-lsp-0.17.0.0
6−- haskell-lsp-types-0.17.0.0
7−- lsp-test-0.8.0.0
5+- haskell-lsp-0.18.0.0
6+- haskell-lsp-types-0.18.0.0
7+- lsp-test-0.8.2.0
88- hie-bios-0.2.0
99- ghc-lib-parser-8.8.1
1010- ghc-lib-8.8.1
stack.yaml+3−3
@@ -2,9 +2,9 @@ resolver: nightly-2019-09-16
22packages:
33- .
44extra-deps:
5−- haskell-lsp-0.17.0.0
6−- haskell-lsp-types-0.17.0.0
7−- lsp-test-0.8.0.0
5+- haskell-lsp-0.18.0.0
6+- haskell-lsp-types-0.18.0.0
7+- lsp-test-0.8.2.0
88- hie-bios-0.2.1
99nix:
1010 packages: [zlib]
stack84.yaml+3−3
@@ -3,9 +3,9 @@ packages:
33- .
44
55extra-deps:
6−- haskell-lsp-0.17.0.0
7−- haskell-lsp-types-0.17.0.0
8−- lsp-test-0.8.0.0
6+- haskell-lsp-0.18.0.0
7+- haskell-lsp-types-0.18.0.0
8+- lsp-test-0.8.2.0
99- rope-utf16-splay-0.3.1.0
1010- shake-0.18.3
1111- filepattern-0.1.1
stack88.yaml+3−2
@@ -2,8 +2,9 @@ resolver: nightly-2019-10-27
22packages:
33- .
44extra-deps:
5−- haskell-lsp-0.17.0.0
6−- lsp-test-0.8.0.0
5+- haskell-lsp-0.18.0.0
6+- haskell-lsp-types-0.18.0.0
7+- lsp-test-0.8.2.0
78- hslogger-1.3.0.0
89- network-bsd-2.8.1.0
910allow-newer: true
test/exe/Main.hs+5−5
@@ -59,8 +59,8 @@ initializeResponseTests = withResource acquire release tests where
5959 , chk "NO completion" _completionProvider Nothing
6060 , chk "NO signature help" _signatureHelpProvider Nothing
6161 , chk " goto definition" _definitionProvider (Just True)
62− , chk "NO goto type definition" _typeDefinitionProvider Nothing
63− , chk "NO goto implementation" _implementationProvider Nothing
62+ , chk "NO goto type definition" _typeDefinitionProvider (Just $ GotoOptionsStatic False)
63+ , chk "NO goto implementation" _implementationProvider (Just $ GotoOptionsStatic False)
6464 , chk "NO find references" _referencesProvider Nothing
6565 , chk "NO doc highlight" _documentHighlightProvider Nothing
6666 , chk "NO doc symbol" _documentSymbolProvider Nothing
@@ -72,10 +72,10 @@ initializeResponseTests = withResource acquire release tests where
7272 _documentRangeFormattingProvider Nothing
7373 , chk "NO doc formatting on typing"
7474 _documentOnTypeFormattingProvider Nothing
75− , chk "NO renaming" _renameProvider Nothing
75+ , chk "NO renaming" _renameProvider (Just $ RenameOptionsStatic False)
7676 , chk "NO doc link" _documentLinkProvider Nothing
77− , chk "NO color" _colorProvider Nothing
78− , chk "NO folding range" _foldingRangeProvider Nothing
77+ , chk "NO color" _colorProvider (Just $ ColorOptionsStatic False)
78+ , chk "NO folding range" _foldingRangeProvider (Just $ FoldingRangeOptionsStatic False)
7979 , chk "NO execute command" _executeCommandProvider Nothing
8080 , chk "NO workspace" _workspace nothingWorkspace
8181 , chk "NO experimental" _experimental Nothing