[GHC] #11469: GHCi should get LANGUAGE extensions/defaulting from the module whose full top-level scope is visible

GHC ghc-devs at haskell.org
Sat Jan 23 15:29:39 UTC 2016


#11469: GHCi should get LANGUAGE extensions/defaulting from the module whose full
top-level scope is visible
-------------------------------------+-------------------------------------
        Reporter:  ezyang            |                Owner:
            Type:  feature request   |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  GHCi              |              Version:  7.11
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by goldfire):

 I really like this general idea but I have some minor quibbles in the
 details. I propose this behavior when compiling a line of code in GHCi:

  * Start with the baseline !DynFlags
  * Apply flags specified on the original command-line
  * Apply GHCi baseline command-prompt flags (e.g. special defaulting
 rules)
  * If there is a fully-open module M, apply flags specified in M itself.
  * Apply flags specified by :set in this GHCi session.
  * Apply flags specified by :seti in this GHCi session

 The idea is that if a user asks GHCi for a behavior, the user should get
 that behavior, regardless of any open modules. With the originally
 proposed order, it would be impossible to countermand a choice made in the
 fully open module.

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11469#comment:2>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list