th-desugar: Functions to desugar Template Haskell

[ bsd3, library, template-haskell ] [ Propose Tags ]

This package provides the Language.Haskell.TH.Desugar module, which desugars Template Haskell's rich encoding of Haskell syntax into a simpler encoding. This desugaring discards surface syntax information (such as the use of infix operators) but retains the original meaning of the TH code. The intended use of this package is as a preprocessor for more advanced code manipulation tools. Note that the input to any of the ds... functions should be produced from a TH quote, using the syntax [| ... |]. If the input to these functions is a hand-coded TH syntax tree, the results may be unpredictable. In particular, it is likely that promoted datatypes will not work as expected.


[Skip to Readme]
Versions 1.0.0, 1.1.0, 1.1.1, 1.2.0, 1.2.1, 1.3.0, 1.3.1, 1.4.0, 1.4.1, 1.4.2, 1.4.2.1, 1.5, 1.5.1, 1.5.2, 1.5.3, 1.5.4, 1.5.4.1, 1.5.5, 1.6, 1.7, 1.8, 1.9
Change log CHANGES.md
Dependencies base (==4.*), containers (>=0.5), mtl (>=2.1), syb (>=0.4), template-haskell (<2.10) [details]
License BSD-3-Clause
Author Richard Eisenberg <eir@cis.upenn.edu>
Maintainer Richard Eisenberg <eir@cis.upenn.edu>
Revised Revision 1 made by HerbertValerioRiedel at Sun Jan 17 19:36:33 UTC 2016
Category Template Haskell
Home page http://www.cis.upenn.edu/~eir/packages/th-desugar
Bug tracker https://github.com/goldfirere/th-desugar/issues
Source repo this: git clone https://github.com/goldfirere/th-desugar.git(tag v1.2.1)
Uploaded by RichardEisenberg at Wed Oct 30 18:16:55 UTC 2013
Distributions Arch:1.9, LTSHaskell:1.8, NixOS:1.9, Stackage:1.9
Downloads 17184 total (199 in the last 30 days)
Rating (no votes yet) [estimated by rule of succession]
Your Rating
  • λ
  • λ
  • λ
Status Docs available [build log]
Successful builds reported [all 1 reports]
Hackage Matrix CI

Modules

[Index]

Downloads

Note: This package has metadata revisions in the cabal description newer than included in the tarball. To unpack the package including the revisions, use 'cabal get'.

Maintainer's Corner

For package maintainers and hackage trustees


Readme for th-desugar-1.2.1

[back to package description]

th-desugar Package

This package provides the Language.Haskell.TH.Desugar module, which desugars Template Haskell's rich encoding of Haskell syntax into a simpler encoding. This desugaring discards surface syntax information (such as the use of infix operators) but retains the original meaning of the TH code. The intended use of this package is as a preprocessor for more advanced code manipulation tools. Note that the input to any of the ds... functions should be produced from a TH quote, using the syntax [| ... |]. If the input to these functions is a hand-coded TH syntax tree, the results may be unpredictable. In particular, it is likely that promoted datatypes will not work as expected.

The package was designed for use with the singletons package, so some design decisions are based on that use case, when more than one design choice was possible.

I will try to keep this package up-to-date with respect to changes in GHC.