Skip to content

ghci: Importing specific non-existent names from a module breaks later imports

At the ghci prompt, attempting to import specific non-existent names from a module breaks any future import attempts, causing them to fail with the same error message that the original import failed with (in addition to any error message they generate themselves). For example:

Prelude> import System.IO(foo)

<interactive>:1:18: Module `System.IO' does not export `foo'
Prelude> import Control.Monad.Error

<interactive>:1:18: Module `System.IO' does not export `foo'

Or compounding the problem:

Prelude> import System.IO(foo)

<interactive>:1:18: Module `System.IO' does not export `foo'
Prelude> import Control.Monad.Error(foo)

<interactive>:1:18: Module `System.IO' does not export `foo'

<interactive>:1:28:
    Module `Control.Monad.Error' does not export `foo'
Prelude> import Control.Monad.Error

<interactive>:1:18: Module `System.IO' does not export `foo'
Trac metadata
Trac field Value
Version 7.4.1
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information