From fd13689339f880e3dace22c9b2cd0bf25fc0c072 Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Mon, 8 Aug 2011 01:34:21 +0000 Subject: [PATCH] missing type signatures --- hledger-lib/Hledger/Utils.hs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hledger-lib/Hledger/Utils.hs b/hledger-lib/Hledger/Utils.hs index a6066a824..a06709dbd 100644 --- a/hledger-lib/Hledger/Utils.hs +++ b/hledger-lib/Hledger/Utils.hs @@ -347,10 +347,13 @@ parseWithCtx ctx p = runParser p ctx "" fromparse :: Either ParseError a -> a fromparse = either parseerror id +parseerror :: ParseError -> a parseerror e = error' $ showParseError e +showParseError :: ParseError -> String showParseError e = "parse error at " ++ show e +showDateParseError :: ParseError -> String showDateParseError e = printf "date parse error (%s)" (intercalate ", " $ tail $ lines $ show e) nonspace :: GenParser Char st Char