#2362: allow full import syntax in GHCi
---------------------------------+------------------------------------------
    Reporter:  Isaac Dupree      |        Owner:                  
        Type:  feature request   |       Status:  new             
    Priority:  normal            |    Milestone:  6.10 branch     
   Component:  Compiler          |      Version:  6.8.2           
    Severity:  normal            |   Resolution:                  
    Keywords:  ghci, import      |   Difficulty:  Unknown         
    Testcase:                    |           Os:  Unknown/Multiple
Architecture:  Unknown/Multiple  |  
---------------------------------+------------------------------------------
Comment (by simonmar):

 I think it should be part of the GHC API, as a generalisation of API used
 by `:module` (`setContext`).  Perhaps `setContext` should take a
 `[ImportDecl]`, and we'd also need a way to parse a `String` into an
 `ImportDecl`.  We also need to think about how to handle `import *M`.

 For the implementation itself, a good place to start seems to be
 `RnNames.rnImports`, which returns a `GlobalRdrEnv` - exactly what we need
 to put in the `InteractiveContext`.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2362#comment:8>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to