
#10803: New TypeSignatureSections extension -------------------------------------+------------------------------------- Reporter: hvr | Owner: Type: bug | Status: new Priority: normal | Milestone: 7.12.1 Component: Compiler | Version: 7.10.2 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Revisions: -------------------------------------+------------------------------------- Description changed by hvr: Old description:
Originally [http://augustss.blogspot.co.at/2014/04/a-small-haskell- extension.html proposed by Lennart Augustsson]
Incomplete work-in-progress can be found in [https://git.haskell.org/ghc.git/log/refs/heads/wip/T10803 wip/T10803] branch
= Preliminary specification
Have
- `(::` ''type'' `)`
be syntax sugar for
- `(\x -> x ::` ''type'' `)`
This new syntax extension is enabled via a new `TypeSignatureSections` language pragma, i.e.
{{{#!hs {-# LANGUAGE TypeSignatureSections #-} }}}
Typing judgement:
{{{ _________________________ G ⊢ (:: ty) :: ty -> ty }}}
TODO: formalise this a bit more
New description: Originally [http://augustss.blogspot.co.at/2014/04/a-small-haskell- extension.html proposed by Lennart Augustsson] Incomplete work-in-progress can be found in [https://git.haskell.org/ghc.git/log/refs/heads/wip/T10803 wip/T10803] branch = Preliminary specification Have - `(::` ''type'' `)` be syntax sugar for - `(\x -> x ::` ''type'' `)` This new syntax extension is enabled via a new `SignatureSections` or maybe `TypeSignatureSections` language pragma, e.g. {{{#!hs {-# LANGUAGE TypeSignatureSections #-} }}} Typing judgement: {{{ _________________________ G ⊢ (:: ty) :: ty -> ty }}} TODO: formalise this a bit more -- -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/10803#comment:7 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler