[{"a"
:0,"b":
1}
,{
...so on
import qualified Pipes.Aeson.Unchecked as PU
import Control.Lens (zoom)
data Foo = Foo { a :: Int, b :: Int } deriving Show
parseFoo :: MonadIO m => Producer PS.ByteString m () -> Producer Foo m ()
parseFoo input = do
fmap snd $ runStateT (zoom PU.decoded parser) (hoist lift input)
return ()
where parser :: Monad m => Parser Foo (Producer Foo m) ()
parser = foldAllM (const $ yield) (return ()) return
--
You received this message because you are subscribed to the Google Groups "Haskell Pipes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to haskell-pipe...@googlegroups.com.
To post to this group, send email to haskel...@googlegroups.com.