
#10747: Infix pattern synonyms fail to parse (regression) -------------------------------------+------------------------------------- Reporter: heisenbug | Owner: Type: bug | Status: new Priority: high | Milestone: Component: Compiler | Version: 7.10.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: GHC rejects | Unknown/Multiple valid program | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Revisions: -------------------------------------+------------------------------------- Changes (by rwbarton): * priority: normal => high * version: 7.11 => 7.10.1 Old description:
{{{#!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" }}}
New description: {{{#!hs {-# LANGUAGE PatternSynonyms #-} pattern head `Cons` tail = head : tail }}} In v7.10 I get: {{{ [1 of 1] Compiling Main ( pat.hs, interpreted ) pat.hs:2:14: parse error on input ?`? }}} In v7.8 I get: {{{ [1 of 1] Compiling Main ( ph.hs, interpreted ) Ok, modules loaded: Main. *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#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler