packages feed

ginger 0.1.2.0 → 0.1.3.0

raw patch · 2 files changed

+15/−4 lines, 2 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

ginger.cabal view
@@ -2,7 +2,7 @@ -- documentation, see http://haskell.org/cabal/users-guide/  name:                ginger-version:             0.1.2.0+version:             0.1.3.0 synopsis:            An implementation of the Jinja2 template language in Haskell description:         Ginger is Jinja, minus the most blatant pythonisms. Wants                      to be feature complete, but isn't quite there yet.
src/Text/Ginger/Parse.hs view
@@ -231,10 +231,21 @@ ifStmtP = do     condExpr <- fancyTagP "if" expressionP     trueStmt <- statementsP-    falseStmt <- option NullS $ do-        try $ simpleTagP "else"-        statementsP+    falseStmt <- elifBranchP <|> elseBranchP <|> return NullS     simpleTagP "endif"+    return $ IfS condExpr trueStmt falseStmt++elseBranchP :: Monad m => Parser m Statement+elseBranchP = do+    try $ simpleTagP "else"+    statementsP++elifBranchP :: Monad m => Parser m Statement+elifBranchP = do+    condExpr <- try $ fancyTagP "elif" expressionP+    trueStmt <- statementsP+    falseStmt <- elifBranchP <|> elseBranchP <|> return NullS+    -- No endif here: the parent {% if %} owns that one.     return $ IfS condExpr trueStmt falseStmt  setStmtP :: Monad m => Parser m Statement