[GHC] #8581: Add support for explicitly-bidirectional pattern synonyms
GHC
ghc-devs at haskell.org
Tue Apr 22 23:07:02 UTC 2014
#8581: Add support for explicitly-bidirectional pattern synonyms
-------------------------------------+------------------------------------
Reporter: cactus | Owner: cactus
Type: feature request | Status: new
Priority: normal | Milestone:
Component: Compiler | Version:
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture: Unknown/Multiple
Type of failure: None/Unknown | Difficulty: Unknown
Test Case: | Blocked By: 5144
Blocking: | Related Tickets:
-------------------------------------+------------------------------------
Comment (by Iceland_jack):
This would be very nice to have, +1.
The possibility of `_` being a shorthand for `undefined` is intriguing. It
allows `_` to be a run-of-the-mill pattern exported by `Prelude` that may
be redefined by users! The regular wildcard meaning where the expression
is `undefined` could be defined as such with the proposed syntax:
{{{
pattern _ <- a where
_ = undefined
failure :: a -> b
failure _ = _
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8581#comment:2>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list