X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2Fmain%2FGHC.hs;h=9e2b3068e623dddbf6c7ea10bc2e92800c9ac503;hb=431453c003b867a2fe33d8634ee830d062be5a96;hp=b00f79f150b63e9efd13fbe4ac66328ba12b0cd5;hpb=703ca1542c8e0983cc9d8eebce6e9f3dd3fd71e2;p=ghc-hetmet.git diff --git a/compiler/main/GHC.hs b/compiler/main/GHC.hs index b00f79f..9e2b306 100644 --- a/compiler/main/GHC.hs +++ b/compiler/main/GHC.hs @@ -2342,8 +2342,11 @@ cyclicModuleErr ms -- | Inform GHC that the working directory has changed. GHC will flush -- its cache of module locations, since it may no longer be valid. --- Note: if you change the working directory, you should also unload --- the current program (set targets to empty, followed by load). +-- +-- Note: Before changing the working directory make sure all threads running +-- in the same session have stopped. If you change the working directory, +-- you should also unload the current program (set targets to empty, +-- followed by load). workingDirectoryChanged :: GhcMonad m => m () workingDirectoryChanged = withSession $ (liftIO . flushFinderCaches) @@ -2533,7 +2536,7 @@ packageDbModules only_exposed = do return $ [ mkModule pid modname | p <- pkgs , not only_exposed || exposed p - , pid <- [mkPackageId (package p)] + , let pid = packageConfigId p , modname <- exposedModules p ] -- -----------------------------------------------------------------------------