[GHC] #10747: Infix pattern synonyms fail to parse (regression)

GHC ghc-devs at haskell.org
Thu Aug 6 15:28:36 UTC 2015


#10747: Infix pattern synonyms fail to parse (regression)
-------------------------------------+-------------------------------------
              Reporter:  heisenbug   |             Owner:
                  Type:  bug         |            Status:  new
              Priority:  normal      |         Milestone:
             Component:  Compiler    |           Version:  7.11
              Keywords:              |  Operating System:  Unknown/Multiple
          Architecture:              |   Type of failure:  GHC rejects
  Unknown/Multiple                   |  valid program
             Test Case:              |        Blocked By:
              Blocking:              |   Related Tickets:
Differential Revisions:              |
-------------------------------------+-------------------------------------
 {{{#!hs
 {-# LANGUAGE PatternSynonyms #-}
 pattern head `Cons` tail = head : tail
 }}}

 In v7.11 I get:
 {{{
 [1 of 1] Compiling Main             ( pat.hs, interpreted )

 pat.hs:2:14: parse error on input ?`?

 }}}

 In v7.10 I get:
 {{{
 *Main> :set -XPatternSynonyms
 *Main> let h `Cons` t = "ht"
 *Main> h
 'h'
 *Main> t
 "t"
 }}}

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


More information about the ghc-tickets mailing list