1
0
forked from GitHub/gf-core

Better error message for Predef.error

+ Instead of "Internal error in ...", you now get a proper error message with
  a source location and a function name.
+ Also added some missing error value propagation in the partial evaluator.
+ Also some other minor cleanup and error handling fixes.
This commit is contained in:
hallgren
2013-01-28 16:12:56 +00:00
parent 3360cc904c
commit 713e883ad7
6 changed files with 62 additions and 37 deletions

View File

@@ -109,7 +109,7 @@ delta f vs =
[v1,v2] -> toValue `fmap` (f `fmap` fromValue v1 `ap` fromValue v2)
_ -> delay
unimpl id = bug $ "unimplemented predefined function: "++showIdent id
-- unimpl id = bug $ "unimplemented predefined function: "++showIdent id
-- problem id vs = bug $ "unexpected arguments: Predef."++showIdent id++" "++show vs
tk i s = take (max 0 (length s - i)) s :: String