Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- parseJsonValue :: Json -> Either String Int
- parseJsonValue =
- caseJsonNumber (Left "") (\_ -> Right 12345)
- parseJson_ :: Json -> Either String (List Int)
- parseJson_ value =
- caseJsonObject (Left "bla") handleObject value
- where
- handleObject object =
- Object.foldM add mempty object
- add memo key value =
- parseJsonValue value
- # map (\x -> x : memo)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement