[commit: ghc] master: Support stage 1 Template Haskell (non-quasi) quotes, fixes #10382. (f16ddce)
git at git.haskell.org
git at git.haskell.org
Mon May 11 16:08:32 UTC 2015
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/f16ddcee0c64a92ab911a7841a8cf64e3ac671fd/ghc
>---------------------------------------------------------------
commit f16ddcee0c64a92ab911a7841a8cf64e3ac671fd
Author: Edward Z. Yang <ezyang at cs.stanford.edu>
Date: Mon May 4 16:10:05 2015 -0700
Support stage 1 Template Haskell (non-quasi) quotes, fixes #10382.
Summary:
This commit adds stage 1 support for Template Haskell
quoting, e.g. [| ... expr ... |], which is useful
for authors of quasiquoter libraries that do not actually
need splices. The TemplateHaskell extension now does not
unconditionally fail; it only fails if the renamer encounters
a splice that it can't run.
In order to make sure the referenced data structures
are consistent, template-haskell is now a boot library.
There are some minor BC changes to template-haskell to make it boot
on GHC 7.8.
Note for reviewer: big diff changes are simply code
being moved out of an ifdef; there was no other substantive
change to that code.
Signed-off-by: Edward Z. Yang <ezyang at cs.stanford.edu>
Test Plan: validate
Reviewers: simonpj, austin, goldfire
Subscribers: bgamari, thomie
Differential Revision: https://phabricator.haskell.org/D876
GHC Trac Issues: #10382
>---------------------------------------------------------------
f16ddcee0c64a92ab911a7841a8cf64e3ac671fd
compiler/deSugar/DsExpr.hs | 8 -
compiler/ghc.cabal.in | 4 +-
compiler/main/DynFlags.hs | 27 +-
compiler/main/HscMain.hs | 4 +-
compiler/rename/RnSplice.hs | 308 ++++++++++-----------
compiler/typecheck/TcExpr.hs | 10 -
compiler/typecheck/TcSplice.hs | 173 ++++++------
docs/users_guide/7.12.1-notes.xml | 7 +-
docs/users_guide/glasgow_exts.xml | 4 +-
ghc.mk | 2 +-
.../template-haskell/Language/Haskell/TH/PprLib.hs | 5 +-
.../template-haskell/Language/Haskell/TH/Syntax.hs | 13 +-
libraries/template-haskell/template-haskell.cabal | 9 +-
mk/warnings.mk | 1 +
testsuite/tests/quotes/.gitignore | 4 +
testsuite/tests/{annotations => quotes}/Makefile | 0
testsuite/tests/quotes/T10384.hs | 3 +
testsuite/tests/quotes/T10384.stderr | 6 +
testsuite/tests/{th => quotes}/T2632.hs | 2 -
testsuite/tests/{th => quotes}/T2931.hs | 1 -
testsuite/tests/{th => quotes}/T3572.hs | 0
testsuite/tests/{th => quotes}/T3572.stdout | 0
testsuite/tests/{th => quotes}/T4056.hs | 2 +-
testsuite/tests/{th => quotes}/T4169.hs | 2 -
testsuite/tests/{th => quotes}/T4170.hs | 1 -
testsuite/tests/{th => quotes}/T5721.hs | 2 +-
testsuite/tests/{th => quotes}/T6062.hs | 1 -
testsuite/tests/quotes/T8455.hs | 5 +
testsuite/tests/{th => quotes}/T8633.hs | 0
testsuite/tests/{th => quotes}/T8759a.hs | 2 +-
testsuite/tests/{th => quotes}/T8759a.stderr | 0
testsuite/tests/{th => quotes}/T9824.hs | 1 -
.../tests/{th => quotes}/TH_abstractFamily.hs | 0
.../tests/{th => quotes}/TH_abstractFamily.stderr | 0
testsuite/tests/{th => quotes}/TH_bracket1.hs | 0
testsuite/tests/{th => quotes}/TH_bracket2.hs | 0
testsuite/tests/{th => quotes}/TH_bracket3.hs | 0
testsuite/tests/quotes/TH_localname.hs | 3 +
testsuite/tests/quotes/TH_localname.stderr | 22 ++
testsuite/tests/{th => quotes}/TH_ppr1.hs | 0
testsuite/tests/{th => quotes}/TH_ppr1.stdout | 0
testsuite/tests/{th => quotes}/TH_reifyType1.hs | 0
testsuite/tests/{th => quotes}/TH_reifyType2.hs | 0
testsuite/tests/{th => quotes}/TH_repE1.hs | 0
testsuite/tests/{th => quotes}/TH_repE3.hs | 0
testsuite/tests/{th => quotes}/TH_scope.hs | 0
.../tests/{th => quotes}/TH_spliceViewPat/A.hs | 0
.../tests/{th => quotes}/TH_spliceViewPat/Main.hs | 0
.../tests/{th => quotes}/TH_spliceViewPat/Makefile | 0
.../TH_spliceViewPat/TH_spliceViewPat.stdout | 0
.../tests/{th => quotes}/TH_spliceViewPat/test.T | 5 -
testsuite/tests/{th => quotes}/TH_tf2.hs | 0
testsuite/tests/quotes/all.T | 31 +++
testsuite/tests/th/T8455.hs | 5 -
testsuite/tests/th/all.T | 31 +--
55 files changed, 359 insertions(+), 345 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 f16ddcee0c64a92ab911a7841a8cf64e3ac671fd
More information about the ghc-commits
mailing list