File tree 5 files changed +9
-9
lines changed 5 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -57,7 +57,7 @@ import GHC hiding (def)
57
57
import GHC.Check (runTimeVersion , compileTimeVersionFromLibdir )
58
58
-- import GhcMonad
59
59
import HIE.Bios.Cradle
60
- import HIE.Bios.Environment (addCmdOpts )
60
+ import HIE.Bios.Environment (addCmdOpts , makeDynFlagsAbsolute )
61
61
import HIE.Bios.Types
62
62
import HscTypes (HscEnv (.. ), ic_dflags )
63
63
import qualified Language.Haskell.LSP.Core as LSP
@@ -523,10 +523,10 @@ memoIO op = do
523
523
Just res -> return (mp, res)
524
524
525
525
setOptions :: GhcMonad m => ComponentOptions -> DynFlags -> m (DynFlags , [Target ])
526
- setOptions (ComponentOptions theOpts _compRoot _) dflags = do
526
+ setOptions (ComponentOptions theOpts compRoot _) dflags = do
527
527
cacheDir <- liftIO $ getCacheDir theOpts
528
- -- (dflags' , targets) <- addCmdOpts compRoot theOpts dflags
529
- ( dflags', targets) <- addCmdOpts theOpts dflags
528
+ (dflags_ , targets) <- addCmdOpts theOpts dflags
529
+ let dflags' = makeDynFlagsAbsolute compRoot dflags_
530
530
let dflags'' =
531
531
-- disabled, generated directly by ghcide instead
532
532
flip gopt_unset Opt_WriteInterface $
Original file line number Diff line number Diff line change @@ -125,7 +125,7 @@ codeLens _lf ideState plId CodeLensParams{_textDocument=TextDocumentIdentifier u
125
125
logInfo (ideLogger ideState) " Example.codeLens entered (ideLogger)" -- AZ
126
126
case uriToFilePath' uri of
127
127
Just (toNormalizedFilePath -> filePath) -> do
128
- _ <- runAction (fromNormalizedFilePath filePath) ideState $ runMaybeT $ useE TypeCheck filePath
128
+ _ <- runAction " Example.codeLens " ideState $ runMaybeT $ useE TypeCheck filePath
129
129
_diag <- getDiagnostics ideState
130
130
_hDiag <- getHiddenDiagnostics ideState
131
131
let
@@ -190,7 +190,7 @@ logAndRunRequest label getResults ide pos path = do
190
190
logInfo (ideLogger ide) $
191
191
label <> " request at position " <> T. pack (showPosition pos) <>
192
192
" in file: " <> T. pack path
193
- runAction path ide $ getResults filePath pos
193
+ runAction " Example " ide $ getResults filePath pos
194
194
195
195
-- ---------------------------------------------------------------------
196
196
Original file line number Diff line number Diff line change @@ -187,7 +187,7 @@ logAndRunRequest label getResults ide pos path = do
187
187
logInfo (ideLogger ide) $
188
188
label <> " request at position " <> T. pack (showPosition pos) <>
189
189
" in file: " <> T. pack path
190
- runAction path ide $ getResults filePath pos
190
+ runAction " Example2 " ide $ getResults filePath pos
191
191
192
192
-- ---------------------------------------------------------------------
193
193
Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ doFormatting lf providers ideState ft uri params = do
65
65
Just provider ->
66
66
case uriToFilePath uri of
67
67
Just (toNormalizedFilePath -> fp) -> do
68
- (_, mb_contents) <- runAction (fromNormalizedFilePath fp) ideState $ getFileContents fp
68
+ (_, mb_contents) <- runAction " Formatter " ideState $ getFileContents fp
69
69
case mb_contents of
70
70
Just contents -> do
71
71
logDebug (ideLogger ideState) $ T. pack $
Original file line number Diff line number Diff line change @@ -76,7 +76,7 @@ provider ideState typ contents fp _ = do
76
76
in
77
77
return $ map DynOption $ pp <> pm <> ex
78
78
79
- m_parsed <- runAction (fromNormalizedFilePath fp) ideState $ getParsedModule fp
79
+ m_parsed <- runAction " Ormolu " ideState $ getParsedModule fp
80
80
fileOpts <- case m_parsed of
81
81
Nothing -> return []
82
82
Just pm -> fromDyn pm
You can’t perform that action at this time.
0 commit comments