[GHC] #11243: Use Type Synonyms to Compress Errors

GHC ghc-devs at haskell.org
Thu Dec 17 17:41:21 UTC 2015


#11243: Use Type Synonyms to Compress Errors
-------------------------------------+-------------------------------------
        Reporter:  crockeea          |                Owner:
            Type:  feature request   |               Status:  new
        Priority:  normal            |            Milestone:  8.2.1
       Component:  Compiler          |              Version:  7.10.2
      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 simonpj):

 > I believe that GHC attempts to expand type synonyms as much as possible

 On the contrary, GHC tries ''not'' to expand type synonyms unless
 necessary.

 So the first thing to do is to look at a small example, and see why it is
 failing to not-expand them.  Can you make a test case that is as small as
 possible, in which a type synoym is expanded that you'd rather wasn't?
 (I.e. NOT one that demonstrates (as above) that unnecessary expansion is
 undesirable; we all believe that already.)

 It's possible that there's a good reason.  Then the next thing is to think
 whether we could improve GHC's existing techniques for delaying expansion.

 Finally you could try to re-compress expanded types, though that sounds
 harder.

 Definitely a good project!

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


More information about the ghc-tickets mailing list