File tree Expand file tree Collapse file tree 3 files changed +5
-9
lines changed
session-loader/Development/IDE Expand file tree Collapse file tree 3 files changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -610,12 +610,11 @@ loadSessionWithOptions recorder SessionLoadingOptions{..} dir = do
610
610
[ " No cradle target found. Is this file listed in the targets of your cradle?"
611
611
, " If you are using a .cabal file, please ensure that this module is listed in either the exposed-modules or other-modules section"
612
612
]
613
+
614
+ void $ modifyVar' fileToFlags $ Map. insert hieYaml this_flags_map
615
+ void $ modifyVar' filesMap $ flip HM. union (HM. fromList (map ((,hieYaml) . fst ) $ concatMap toFlagsMap all_targets))
613
616
-- The VFS doesn't change on cradle edits, re-use the old one.
614
617
restartShakeSession VFSUnmodified " new component" [] $ do
615
- void $ modifyVar' fileToFlags $
616
- Map. insert hieYaml this_flags_map
617
- void $ modifyVar' filesMap $
618
- flip HM. union (HM. fromList (map ((,hieYaml) . fst ) $ concatMap toFlagsMap all_targets))
619
618
key1 <- extendKnownTargets all_targets
620
619
key2 <- invalidateShakeCache
621
620
return [key1, key2]
Original file line number Diff line number Diff line change @@ -124,7 +124,6 @@ modifyFileExists state changes = do
124
124
let keys1 = map (toKey GetFileExists . fst ) fileExistChanges
125
125
let keys2 = map (toKey GetModificationTime . fst ) fileModifChanges
126
126
return (keys1 <> keys2)
127
- return keys
128
127
129
128
fromChange :: FileChangeType -> Maybe Bool
130
129
fromChange FileChangeType_Created = Just True
Original file line number Diff line number Diff line change @@ -250,10 +250,8 @@ typecheckParentsAction recorder nfp = do
250
250
setSomethingModified :: VFSModified -> IdeState -> String -> IO [Key ] -> IO ()
251
251
setSomethingModified vfs state reason actionBetweenSession = do
252
252
-- Update database to remove any files that might have been renamed/deleted
253
- void $ restartShakeSession (shakeExtras state) vfs reason [] $ do
254
- keys <- actionBetweenSession
255
- atomically $ writeTQueue (indexQueue $ hiedbWriter $ shakeExtras state) (\ withHieDb -> withHieDb deleteMissingRealFiles)
256
- return keys
253
+ atomically $ writeTQueue (indexQueue $ hiedbWriter $ shakeExtras state) (\ withHieDb -> withHieDb deleteMissingRealFiles)
254
+ void $ restartShakeSession (shakeExtras state) vfs reason [] actionBetweenSession
257
255
258
256
registerFileWatches :: [String ] -> LSP. LspT Config IO Bool
259
257
registerFileWatches globs = do
You can’t perform that action at this time.
0 commit comments