
#12109: Matching on pattern synonym succeeds compiled with ghc, fails with ghci -------------------------------------+------------------------------------- Reporter: Iceland_jack | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.0.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 Iceland_jack): {{{#!hs $ ghci -ignore-dot-ghci GHCi, version 8.0.0.20160511: http://www.haskell.org/ghc/ :? for help Prelude> :set -XPatternSynonyms Prelude> :set -XViewPatterns Prelude> pattern Parsed x = [(x, "")] Prelude> pattern Read a <- (reads -> Parsed a) Prelude> let Read x = "420" in (x::Int) 420 }}} works -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12109#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler