[commit: ghc] master: Implement new -XTemplateHaskellQuotes pragma (85fcd03)

git at git.haskell.org git at git.haskell.org
Sun Nov 29 12:22:06 UTC 2015


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/85fcd035f73679927a0539d5f6c9b919517365e1/ghc

>---------------------------------------------------------------

commit 85fcd035f73679927a0539d5f6c9b919517365e1
Author: Herbert Valerio Riedel <hvr at gnu.org>
Date:   Fri Nov 27 13:39:18 2015 +0100

    Implement new -XTemplateHaskellQuotes pragma
    
    Since f16ddcee0c64a92ab911a7841a8cf64e3ac671fd / D876, `ghc-stage1`
    supports a subset of `-XTemplateHaskell`, but since we need Cabal to be
    able detect (so `.cabal` files can be specified accordingly, see also
    GHC #11102 which omits `TemplateHaskell` from `--supported-extensions`)
    whether GHC provides full or only partial `-XTemplateHaskell` support,
    the proper way to accomplish this is to split off the
    quotation/non-splicing `TemplateHaskell` feature-subset into a new
    language pragma `TemplateHaskellQuotes`.
    
    Moreover, `-XTemplateHaskellQuotes` is considered safe under SafeHaskell
    
    This addresses #11121
    
    Reviewers: goldfire, ezyang, dterei, austin, bgamari
    
    Reviewed By: bgamari
    
    Subscribers: thomie
    
    Differential Revision: https://phabricator.haskell.org/D1511
    
    GHC Trac Issues: #11121


>---------------------------------------------------------------

85fcd035f73679927a0539d5f6c9b919517365e1
 compiler/main/DynFlags.hs                          | 28 ++++++++++++++++++----
 compiler/parser/Lexer.x                            | 22 ++++++++++-------
 compiler/rename/RnSplice.hs                        |  9 +++----
 docs/users_guide/7.12.1-notes.rst                  | 10 ++++----
 docs/users_guide/glasgow_exts.rst                  | 13 ++++++----
 testsuite/tests/driver/T4437.hs                    |  1 +
 testsuite/tests/quotes/T10384.hs                   |  2 +-
 testsuite/tests/quotes/all.T                       |  2 +-
 .../safeHaskell/safeLanguage/SafeLang12.stderr     | 11 ++++-----
 utils/mkUserGuidePart/Options/Language.hs          |  7 ++++++
 10 files changed, 71 insertions(+), 34 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 85fcd035f73679927a0539d5f6c9b919517365e1


More information about the ghc-commits mailing list