packages feed

haskellish 0.2.4.1 → 0.2.4.2

raw patch · 2 files changed

+5/−5 lines, 2 files

Files

Language/Haskellish.hs view
@@ -21,7 +21,7 @@  data Haskellish st a = Haskellish { _run :: st -> Exp SrcSpanInfo -> Either ParseError (a,st) } --- runHaskellish, introduced in this form in 0.2.4 and considered *deprecated* in favour of parseExp+-- runHaskellish, introduced in this form in 0.2.4 and considered *deprecated* in favour of parseAndRun -- is primarily meant to avoid breaking changes with projects built against 0.2.3 and earlier  runHaskellish :: Haskellish st a -> st -> Exp SrcSpanInfo -> Either String (a,st)@@ -31,12 +31,12 @@     Left (NonFatal ((a,b),_) t) -> Left $ show a ++ ":" ++ show b ++ " " ++ T.unpack t     Left (Fatal ((a,b),_) t) -> Left $ show a ++ ":" ++ show b ++ " " ++ T.unpack t --- parseExp replaces runHaskellish and is intended as the main top-level entry point for+-- parseAndRun replaces runHaskellish and is intended as the main top-level entry point for -- running a Haskellish parser. It uses haskell-src-exts to parse Text into a Haskell AST -- that is then parsed by the Haskellish parser. -parseExp :: Haskellish st a -> st -> Text -> Either (Span,Text) (a,st)-parseExp h st x = do+parseAndRun :: Haskellish st a -> st -> Text -> Either (Span,Text) (a,st)+parseAndRun h st x = do   case Exts.parseExp (T.unpack x) of     Exts.ParseOk e -> do       case _run h st e of
haskellish.cabal view
@@ -1,5 +1,5 @@ name:                haskellish-version:             0.2.4.1+version:             0.2.4.2 synopsis:            For parsing Haskell-ish languages homepage:            http://github.com/dktr0/Haskellish license:             BSD3