-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Template Haskell support for global configuration data -- -- A template haskell function is provided that allows the programmer to -- write a module as if configuration values were global constants. The -- exported function then expect those configuration values as extra -- parameters. @package seal-module @version 0.1.0.1 -- | This provides a Template Haskell function to convert a set of function -- declarations which use global constants into function declarations -- that take these constants as parameters. -- -- The goal is to make it more convenient to write pure, non-monadic code -- that deep in the call stack requires some configuration data without -- having to pass these paramters around explicitly. module Language.Haskell.SealModule -- | sealedParam turns a toplevel declaration into a sealed -- parameter. It must only be used inside a call to sealModule and -- there only in the form of a top level declaration of the form -- --
-- name = sealedParam ---- -- A type signature for name may be given, and is a prerequisite -- for the generated functions having type signatures. sealedParam :: a -- | sealModule modifies the passed top level declarations to have -- additional parameters for each declaration bound to -- sealedParam, in the order of their appearance. The parameter -- declarations and their type signature, if present, are removed from -- the list of declarations. -- -- The generated functions will have a type signature if and only they -- have a type signature and all parameters have type signatures. sealModule :: Q [Dec] -> Q [Dec]