[commit: ghc] master: Implementation of StrictData language extension (f842ad6)
git at git.haskell.org
git at git.haskell.org
Mon Jul 27 11:49:10 UTC 2015
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/f842ad6c751c14ec331ca1709538c2f3e9a30ae7/ghc
>---------------------------------------------------------------
commit f842ad6c751c14ec331ca1709538c2f3e9a30ae7
Author: Adam Sandberg Eriksson <adam at sandbergericsson.se>
Date: Mon Jul 27 13:18:36 2015 +0200
Implementation of StrictData language extension
This implements the `StrictData` language extension, which lets the
programmer default to strict data fields in datatype declarations on a
per-module basis.
Specification and motivation can be found at
https://ghc.haskell.org/trac/ghc/wiki/StrictPragma
This includes a tricky parser change due to conflicts regarding `~` in
the type level syntax: all ~'s are parsed as strictness annotations (see
`strict_mark` in Parser.y) and then turned into equality constraints at
the appropriate places using `RdrHsSyn.splitTilde`.
Updates haddock submodule.
Test Plan: Validate through Harbormaster.
Reviewers: goldfire, austin, hvr, simonpj, tibbe, bgamari
Reviewed By: simonpj, tibbe, bgamari
Subscribers: lelf, simonpj, alanz, goldfire, thomie, bgamari, mpickering
Differential Revision: https://phabricator.haskell.org/D1033
GHC Trac Issues: #8347
>---------------------------------------------------------------
f842ad6c751c14ec331ca1709538c2f3e9a30ae7
compiler/basicTypes/DataCon.hs | 172 ++++++++++++---------
compiler/basicTypes/MkId.hs | 66 +++++---
compiler/deSugar/DsMeta.hs | 12 +-
compiler/hsSyn/Convert.hs | 4 +-
compiler/hsSyn/HsTypes.hs | 6 +-
compiler/iface/BuildTyCl.hs | 2 +-
compiler/iface/MkIface.hs | 2 +-
compiler/iface/TcIface.hs | 8 +-
compiler/main/DynFlags.hs | 2 +
compiler/parser/Parser.y | 82 +++++-----
compiler/parser/RdrHsSyn.hs | 16 ++
compiler/prelude/TysWiredIn.hs | 2 +-
compiler/typecheck/TcExpr.hs | 4 +-
compiler/typecheck/TcRnDriver.hs | 7 +-
compiler/typecheck/TcSplice.hs | 13 +-
compiler/typecheck/TcTyClsDecls.hs | 26 +++-
compiler/vectorise/Vectorise/Generic/PData.hs | 5 +-
docs/users_guide/flags.xml | 8 +-
docs/users_guide/glasgow_exts.xml | 40 ++++-
testsuite/tests/deSugar/should_run/DsStrictData.hs | 48 ++++++
.../tests/deSugar/should_run/DsStrictData.stdout | 3 +
testsuite/tests/deSugar/should_run/all.T | 1 +
testsuite/tests/driver/T4437.hs | 4 +-
utils/haddock | 2 +-
24 files changed, 364 insertions(+), 171 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 f842ad6c751c14ec331ca1709538c2f3e9a30ae7
More information about the ghc-commits
mailing list