diff options
author | Matthew Pickering <matthewtpickering@gmail.com> | 2019-12-06 17:11:46 +0000 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2020-02-11 18:04:17 -0500 |
commit | 82023524ff050f26bf00be3432a97f1e537caf41 (patch) | |
tree | 27357f3a71baec1bbe8dab1c59ca82e370b3ca44 /docs | |
parent | 58a4ddeff7730d160dd66f19c288f8b5b27679e3 (diff) | |
download | haskell-82023524ff050f26bf00be3432a97f1e537caf41.tar.gz |
TemplateHaskellQuotes: Allow nested splices
There is no issue with nested splices as they do not require any compile
time code execution. All execution is delayed until the top-level
splice.
Diffstat (limited to 'docs')
-rw-r--r-- | docs/users_guide/8.12.1-notes.rst | 3 | ||||
-rw-r--r-- | docs/users_guide/exts/template_haskell.rst | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/docs/users_guide/8.12.1-notes.rst b/docs/users_guide/8.12.1-notes.rst index 8f2c26041e..b1db851d56 100644 --- a/docs/users_guide/8.12.1-notes.rst +++ b/docs/users_guide/8.12.1-notes.rst @@ -46,6 +46,9 @@ Template Haskell ``where`` bindings properly. Previously, such fixity declarations would be dropped when quoted due to a Template Haskell bug. + - The ``-XTemplateHaskellQuotes`` extension now allows nested splices as nested + splices do not lead directly to compile-time evaluation. (!2288) + ``ghc-prim`` library ~~~~~~~~~~~~~~~~~~~~ diff --git a/docs/users_guide/exts/template_haskell.rst b/docs/users_guide/exts/template_haskell.rst index b7e0e4dff2..7998ceda86 100644 --- a/docs/users_guide/exts/template_haskell.rst +++ b/docs/users_guide/exts/template_haskell.rst @@ -48,7 +48,7 @@ Syntax Template Haskell has the following new syntactic constructions. You need to use the extension :extension:`TemplateHaskell` to switch these syntactic extensions on. Alternatively, the :extension:`TemplateHaskellQuotes` extension can be used to -enable the quotation subset of Template Haskell (i.e. without splice syntax). +enable the quotation subset of Template Haskell (i.e. without top-level splices). The :extension:`TemplateHaskellQuotes` extension is considered safe under :ref:`safe-haskell` while :extension:`TemplateHaskell` is not. |