[GHC] #8636: Infix declaration on operators ending on backslash

#8636: Infix declaration on operators ending on backslash ----------------------------+---------------------------------------------- Reporter: | Owner: jcristovao | Status: new Type: bug | Milestone: Priority: normal | Version: 7.7 Component: Compiler | Operating System: Linux Keywords: | Type of failure: GHC rejects valid program Architecture: x86_64 | Test Case: (amd64) | Blocking: Difficulty: Unknown | Blocked By: | Related Tickets: | ----------------------------+---------------------------------------------- Hi, I was trying the latest GHC Head (version 7.7.20131227), when I noticed a regression. I don't know if this is intended behaviour or not. This compiled ok under 7.6.3 {{{ (?&&\) :: (Monoid a) => a -> (a -> Bool) -> a (?&&\) value f = if f value then value else mempty infixl 1 ?&&\ }}} Under 7.7, the infixl declaration only works if I double escape it. {{{ infixl 1 ?&&\\ }}} Is this intended? -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/8636 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#8636: Infix declaration on operators ending on backslash ----------------------------------------------+---------------------------- Reporter: jcristovao | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.7 Resolution: | Keywords: Operating System: Linux | Architecture: x86_64 Type of failure: GHC rejects valid program | (amd64) Test Case: | Difficulty: Unknown Blocking: | Blocked By: | Related Tickets: ----------------------------------------------+---------------------------- Comment (by monoidal): Are you sure? I cannot reproduce the difference in behavior between 7.6 and 7.7. This escaping happens with `-XCPP` flag but it does not seem to be version dependent. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/8636#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#8636: Infix declaration on operators ending on backslash ----------------------------------------------+---------------------------- Reporter: jcristovao | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.7 Resolution: invalid | Keywords: Operating System: Linux | Architecture: x86_64 Type of failure: GHC rejects valid program | (amd64) Test Case: | Difficulty: Unknown Blocking: | Blocked By: | Related Tickets: ----------------------------------------------+---------------------------- Changes (by jcristovao): * status: new => closed * resolution: => invalid Comment: You are absolutly right, I had indeed enabled the CPP extension, and was oblivious of this unintended consequence. Sorry for the noise... -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/8636#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC