heterocephalus 1.0.5.4 → 1.0.5.5
raw patch · 2 files changed
+5/−7 lines, 2 filesdep +template-haskell-compat-v0208PVP ok
version bump matches the API change (PVP)
Dependencies added: template-haskell-compat-v0208
API changes (from Hackage documentation)
Files
- heterocephalus.cabal +2/−1
- src/Text/Heterocephalus.hs +3/−6
heterocephalus.cabal view
@@ -1,5 +1,5 @@ name: heterocephalus-version: 1.0.5.4+version: 1.0.5.5 synopsis: A type-safe template engine for working with front end development tools description: Recent front end development tools and languages are growing fast and have@@ -43,6 +43,7 @@ , parsec >= 3.1 , shakespeare >= 2.0 , template-haskell >= 2.12+ , template-haskell-compat-v0208 , text >= 1.2 , transformers >= 0.5 ghc-options: -Wall -Wcompat -Wnoncanonical-monad-instances
src/Text/Heterocephalus.hs view
@@ -79,6 +79,7 @@ #else import Language.Haskell.TH.Syntax #endif+import TemplateHaskell.Compat.V0208 import Text.Blaze (preEscapedToMarkup) import Text.Blaze.Html (toHtml) import Text.Blaze.Internal (preEscapedText)@@ -495,7 +496,7 @@ case exps of [] -> [|return ()|] [x] -> return x- _ -> return $ DoE $ map NoBindS exps+ _ -> return $ doE $ map NoBindS exps docToExp :: HeterocephalusSetting -> Scope -> Doc -> Q Exp docToExp set scope (DocForall list idents inside) = do@@ -525,11 +526,7 @@ return $ nonUnaryTupE [d', docs'] where nonUnaryTupE :: [Exp] -> Exp- nonUnaryTupE es = TupE $-#if MIN_VERSION_template_haskell(2,16,0)- map Just-#endif- es+ nonUnaryTupE es = tupE es docToExp set scope (DocCase deref cases) = do let exp_ = derefToExp scope deref matches <- mapM toMatch cases