@@ -25,10 +25,12 @@ import Ide.Plugin.Cabal.Completion.Types (ParseCabalFields (..),
25
25
cabalPositionToLSPPosition )
26
26
import Ide.Plugin.Cabal.Orphans ()
27
27
import Ide.Types (PluginMethodHandler )
28
- import qualified Language.LSP.Protocol.Message as LSP
28
+ import Language.LSP.Protocol.Message ( Method ( .. ))
29
29
import qualified Language.LSP.Protocol.Types as LSP
30
+ import Language.LSP.Protocol.Types (DocumentSymbol (.. ))
30
31
31
- moduleOutline :: PluginMethodHandler IdeState LSP. Method_TextDocumentDocumentSymbol
32
+
33
+ moduleOutline :: PluginMethodHandler IdeState Method_TextDocumentDocumentSymbol
32
34
moduleOutline ideState _ LSP. DocumentSymbolParams {_textDocument = LSP. TextDocumentIdentifier uri} =
33
35
case LSP. uriToFilePath uri of
34
36
Just (toNormalizedFilePath' -> fp) -> do
@@ -43,7 +45,7 @@ moduleOutline ideState _ LSP.DocumentSymbolParams {_textDocument = LSP.TextDocum
43
45
-- | Creates a DocumentSumbol object for the
44
46
-- cabal AST, without displaying fieldLines and
45
47
-- displaying Section name and SectionArgs in one line
46
- documentSymbolForField :: Field Position -> Maybe LSP. DocumentSymbol
48
+ documentSymbolForField :: Field Position -> Maybe DocumentSymbol
47
49
documentSymbolForField (Field (Name pos fieldName) _) =
48
50
Just
49
51
(defDocumentSymbol range)
@@ -89,8 +91,8 @@ addNameLengthToLSPRange (LSP.Range pos1 (LSP.Position line char)) name =
89
91
pos1
90
92
(LSP. Position line (char + fromIntegral (T. length name)))
91
93
92
- defDocumentSymbol :: LSP. Range -> LSP. DocumentSymbol
93
- defDocumentSymbol range = LSP. DocumentSymbol {.. }
94
+ defDocumentSymbol :: LSP. Range -> DocumentSymbol
95
+ defDocumentSymbol range = DocumentSymbol {.. }
94
96
where
95
97
_detail = Nothing
96
98
_deprecated = Nothing
0 commit comments