Commit 6bd26f00 authored by Iustin Pop's avatar Iustin Pop
Browse files

htools: small change in error message in THH.hs



We should also display the value we can't parse, otherwise debugging
is very hard.
Signed-off-by: default avatarIustin Pop <iustin@google.com>
Reviewed-by: default avatarAgata Murawska <agatamurawska@google.com>
parent 706f7f51
......@@ -343,7 +343,8 @@ genReadJSON name = do
JSON.Ok s' -> $(varE (fromRawName name)) s'
JSON.Error e ->
JSON.Error $ "Can't parse raw value for type " ++
$(stringE name) ++ ": " ++ e
$(stringE name) ++ ": " ++ e ++ " from " ++
show $(varE s)
|]
return $ FunD (mkName "readJSON") [Clause [VarP s] (NormalB body) []]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment