@@ -81,20 +81,20 @@ import System.Time.Extra (offsetTime,
81
81
import Text.Printf (printf )
82
82
83
83
data Arguments = Arguments
84
- { argsOTMemoryProfiling :: Bool
85
- , argFiles :: Maybe [FilePath ] -- ^ Nothing: lsp server ; Just: typecheck and exit
86
- , argsLogger :: IO Logger
87
- , argsRules :: Rules ()
88
- , argsHlsPlugins :: IdePlugins IdeState
89
- , argsGhcidePlugin :: Plugin Config -- ^ Deprecated
84
+ { argsOTMemoryProfiling :: Bool
85
+ , argFiles :: Maybe [FilePath ] -- ^ Nothing: lsp server ; Just: typecheck and exit
86
+ , argsLogger :: IO Logger
87
+ , argsRules :: Rules ()
88
+ , argsHlsPlugins :: IdePlugins IdeState
89
+ , argsGhcidePlugin :: Plugin Config -- ^ Deprecated
90
90
, argsSessionLoadingOptions :: SessionLoadingOptions
91
- , argsIdeOptions :: Config -> Action IdeGhcSession -> IdeOptions
92
- , argsLspOptions :: LSP. Options
93
- , argsDefaultHlsConfig :: Config
94
- , argsGetHieDbLoc :: FilePath -> IO FilePath -- ^ Map project roots to the location of the hiedb for the project
95
- , argsDebouncer :: IO (Debouncer NormalizedUri ) -- ^ Debouncer used for diagnostics
96
- , argsHandleIn :: IO Handle
97
- , argsHandleOut :: IO Handle
91
+ , argsIdeOptions :: Config -> Action IdeGhcSession -> IdeOptions
92
+ , argsLspOptions :: LSP. Options
93
+ , argsDefaultHlsConfig :: Config
94
+ , argsGetHieDbLoc :: FilePath -> IO FilePath -- ^ Map project roots to the location of the hiedb for the project
95
+ , argsDebouncer :: IO (Debouncer NormalizedUri ) -- ^ Debouncer used for diagnostics
96
+ , argsHandleIn :: IO Handle
97
+ , argsHandleOut :: IO Handle
98
98
}
99
99
100
100
instance Default Arguments where
@@ -145,7 +145,7 @@ defaultMain Arguments{..} = do
145
145
let hlsPlugin = asGhcIdePlugin argsHlsPlugins
146
146
hlsCommands = allLspCmdIds' pid argsHlsPlugins
147
147
plugins = hlsPlugin <> argsGhcidePlugin
148
- options = argsLspOptions { LSP. executeCommandCommands = Just hlsCommands }
148
+ options = argsLspOptions { LSP. executeCommandCommands = Just $ (argsLspOptions LSP. executeCommandCommands) <> hlsCommands }
149
149
argsOnConfigChange = getConfigFromNotification
150
150
rules = argsRules >> pluginRules plugins
151
151
0 commit comments