
#15336: ./System/IO.hs accidentally overridden when running ghci -------------------------------------+------------------------------------- Reporter: luqui | Owner: RolandSenn Type: bug | Status: new Priority: normal | Milestone: 8.8.1 Component: GHCi | Version: 8.2.2 Resolution: | Keywords: Operating System: MacOS X | Architecture: Type of failure: GHC rejects | Unknown/Multiple valid program | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by RolandSenn): @monoidal:
Fixing this will likely also fix #12509
Unfortunately not... #12509 does not enter `loadSrcInterface_maybe` because of `not (safeDirectImpsReq dflags)`. However, this ticket fails somewhere in a subfunction of `loadSrcInterface_maybe`. {{{ Code from compiler/rename/RnEnv.hs: lookupQualifiedNameGHCi :: RdrName -> RnM [Name] lookupQualifiedNameGHCi rdr_name = -- We want to behave as we would for a source file import here, -- and respect hiddenness of modules/packages, hence loadSrcInterface. do { dflags <- getDynFlags ; is_ghci <- getIsGHCi ; go_for_it dflags is_ghci } where go_for_it dflags is_ghci | Just (mod,occ) <- isQual_maybe rdr_name , is_ghci , gopt Opt_ImplicitImportQualified dflags -- Enables this GHCi behaviour , not (safeDirectImpsReq dflags) -- See Note [Safe Haskell and GHCi] = do { res <- loadSrcInterface_maybe doc mod False Nothing <...etc...> }}} -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/15336#comment:7 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler