[GHC] #15685: Pattern signature not inferred

GHC ghc-devs at haskell.org
Thu Oct 4 15:03:40 UTC 2018


#15685: Pattern signature not inferred
-------------------------------------+-------------------------------------
        Reporter:  Iceland_jack      |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:  8.6.1
       Component:  Compiler          |              Version:  8.6.1
      Resolution:                    |             Keywords:
                                     |  PatternSynonyms
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 Simon Peyton Jones <simonpj@…>):

 In [changeset:"9ebfa03d9e9cbf79f698b5d4bd39e799e4e9a02c/ghc" 9ebfa03/ghc]:
 {{{
 #!CommitTicketReference repository="ghc"
 revision="9ebfa03d9e9cbf79f698b5d4bd39e799e4e9a02c"
 Fail fast on pattern synonyms

 We were recovering too eagerly from errors in pattern-synonym
 type inference, leading to a cascade of confusing follow up errors
 (Trac #15685, #15692).

 The underlying issue is that a pattern synonym should have a closed,
 fixed type, with no unification variables in it.  But it wasn't!

 Fixing this made me change the interface to simplifyInfer slightly.
 Instead of /emitting/ a residual implication constraint, it
 now /returns/ it, so that the caller can decide what to do.
 }}}

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


More information about the ghc-tickets mailing list