[GHC] #14340: Rename AND typecheck types before values

GHC ghc-devs at haskell.org
Wed Oct 11 14:27:50 UTC 2017


#14340: Rename AND typecheck types before values
-------------------------------------+-------------------------------------
           Reporter:  ezyang         |             Owner:  (none)
               Type:  task           |            Status:  new
           Priority:  normal         |         Milestone:
          Component:  Compiler       |           Version:  8.2.1
  (Type checker)                     |
           Keywords:                 |  Operating System:  Unknown/Multiple
       Architecture:                 |   Type of failure:  None/Unknown
  Unknown/Multiple                   |
          Test Case:                 |        Blocked By:
           Blocking:                 |   Related Tickets:
Differential Rev(s):                 |         Wiki Page:
-------------------------------------+-------------------------------------
 In a few cases, we get in trouble during renaming of values because we
 don't have access to information that would be computed during
 typechecking. Two examples of this:

 * https://ghc.haskell.org/trac/ghc/ticket/13905 - Here, we need to
 determine if a Name is a newtype constructor or data type constructor
 during renaming (desugaring of applicative do), which is not known until
 after typechecking

 * https://ghc.haskell.org/trac/ghc/ticket/12088 - Perhaps? We want to
 rename and typecheck instance declarations at the same time, since they
 can occur between the type declarations.

 One nit: you can't compute SCCs until you rename. But if you just rename
 ALL of the types at once, then SCC them, that should be fine.

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


More information about the ghc-tickets mailing list