[GHC] #11606: name shadowing warnings don't trigger on standalone declarations in ghci

GHC ghc-devs at haskell.org
Thu Jan 17 17:47:05 UTC 2019


#11606: name shadowing warnings don't trigger on standalone declarations in ghci
-------------------------------------+-------------------------------------
        Reporter:  rwbarton          |                Owner:  (none)
            Type:  bug               |               Status:  closed
        Priority:  high              |            Milestone:  8.8.1
       Component:  GHCi              |              Version:  7.10.3
      Resolution:  fixed             |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
                                     |  ghci/scripts/T11606
      Blocked By:                    |             Blocking:
 Related Tickets:  #16096            |  Differential Rev(s):  MR:97
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by Ömer Sinan Ağacan <omeragacan@…>):

 In [changeset:"a34ee61545930d569d0dbafb3a4a5db3a7a711e5/ghc"
 a34ee615/ghc]:
 {{{
 #!CommitTicketReference repository="ghc"
 revision="a34ee61545930d569d0dbafb3a4a5db3a7a711e5"
 Refactor GHCi UI to fix #11606, #12091, #15721, #16096

 Instead of parsing and executing a statement or declaration directly we
 now parse them first and then execute in a separate step. This gives us
 the flexibility to inspect the parsed declaration before execution.
 Using this we now inspect parsed declarations, and if it's a single
 declaration of form `x = y` we execute it as `let x = y` instead, fixing
 a ton of problems caused by poor declaration support in GHCi.

 To avoid any users of the modules I left `execStmt` and `runDecls`
 unchanged and added `execStmt'` and `runDecls'` which work on parsed
 statements/declarations.
 }}}

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


More information about the ghc-tickets mailing list