[commit: ghc] wip/T8584: Add support for pattern synonym type signatures. Syntax is of the form (34acc90)
git at git.haskell.org
git at git.haskell.org
Wed Nov 19 11:17:12 UTC 2014
Repository : ssh://git@git.haskell.org/ghc
On branch : wip/T8584
Link : http://ghc.haskell.org/trac/ghc/changeset/34acc90ccef765ca6a55b69437a721828a7fba6c/ghc
>---------------------------------------------------------------
commit 34acc90ccef765ca6a55b69437a721828a7fba6c
Author: Dr. ERDI Gergo <gergo at erdi.hu>
Date: Fri Nov 7 19:29:06 2014 +0800
Add support for pattern synonym type signatures.
Syntax is of the form
pattern P :: (Prov b) => (Req a) => a -> b -> Int -> T a
which declares a pattern synonym called `P`, with argument types `a`, `b`,
and `Int`, and result type `T a`, with provided context `(Prov b)` and required
context `(Req a)`.
>---------------------------------------------------------------
34acc90ccef765ca6a55b69437a721828a7fba6c
compiler/hsSyn/HsBinds.lhs | 51 +++---
compiler/hsSyn/HsTypes.lhs | 16 +-
compiler/iface/IfaceSyn.lhs | 25 ++-
compiler/iface/IfaceType.lhs | 15 +-
compiler/parser/Parser.y | 51 ++++--
compiler/parser/RdrHsSyn.hs | 27 +---
compiler/rename/RnBinds.lhs | 42 ++---
compiler/typecheck/TcBinds.lhs | 50 +++++-
compiler/typecheck/TcClassDcl.lhs | 4 +-
compiler/typecheck/TcPat.lhs | 23 ++-
compiler/typecheck/TcPatSyn.lhs | 195 +++++++++++++++++------
compiler/typecheck/TcPatSyn.lhs-boot | 9 +-
testsuite/tests/ghci/scripts/T8776.stdout | 2 +-
testsuite/tests/patsyn/should_compile/T8584-1.hs | 8 +
testsuite/tests/patsyn/should_compile/T8968-1.hs | 8 +
testsuite/tests/patsyn/should_compile/all.T | 2 +
16 files changed, 351 insertions(+), 177 deletions(-)
Diff suppressed because of size. To see it, use:
git diff-tree --root --patch-with-stat --no-color --find-copies-harder --ignore-space-at-eol --cc 34acc90ccef765ca6a55b69437a721828a7fba6c
More information about the ghc-commits
mailing list