Skip to content

Commit 03b0536

Browse files
committed
clean up PartialHandlers definition
The ghcide partial handlers for completions, code actions and hover are not really being used, since they get overriden by the `<> ps` append. This is due to the right-biased semantics of `PartialHandlers`
1 parent 07692de commit 03b0536

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

src/Ide/Main.hs

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -57,14 +57,6 @@ import qualified System.Log.Logger as L
5757
import System.Time.Extra
5858
import Development.Shake (action)
5959

60-
-- ---------------------------------------------------------------------
61-
-- ghcide partialhandlers
62-
import Development.IDE.Plugin.CodeAction as CodeAction
63-
import Development.IDE.Plugin.Completions as Completions
64-
import Development.IDE.LSP.HoverDefinition as HoverDefinition
65-
66-
-- ---------------------------------------------------------------------
67-
6860
ghcIdePlugins :: T.Text -> IdePlugins IdeState -> (Plugin Config, [T.Text])
6961
ghcIdePlugins pid ps = (asGhcIdePlugin ps, allLspCmdIds' pid ps)
7062

@@ -121,10 +113,7 @@ runLspMode lspArgs@LspArguments{..} idePlugins = do
121113

122114
pid <- T.pack . show <$> getProcessID
123115
let
124-
(ps, commandIds) = ghcIdePlugins pid idePlugins
125-
plugins = Completions.plugin <> CodeAction.plugin <>
126-
Plugin mempty HoverDefinition.setHandlersDefinition <>
127-
ps
116+
(plugins, commandIds) = ghcIdePlugins pid idePlugins
128117
options = def { LSP.executeCommandCommands = Just commandIds
129118
, LSP.completionTriggerCharacters = Just "."
130119
}

0 commit comments

Comments
 (0)