aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/cjr_print.sml
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adam@chlipala.net>2013-10-10 18:31:10 -0400
committerGravatar Adam Chlipala <adam@chlipala.net>2013-10-10 18:31:10 -0400
commitb877e9c099be92c78a439e9e9cb6553467f28237 (patch)
tree08d5312366dba0153438c5c857ead3d0d93e696c /src/cjr_print.sml
parent71c58074582c14d4ff6ba38f60be80dad0e36be5 (diff)
Remove uw_cutErrorLocation() hijinks
Diffstat (limited to 'src/cjr_print.sml')
-rw-r--r--src/cjr_print.sml12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/cjr_print.sml b/src/cjr_print.sml
index d2f77a36..bc8f1be6 100644
--- a/src/cjr_print.sml
+++ b/src/cjr_print.sml
@@ -1617,8 +1617,11 @@ and p_exp' par tail env (e, loc) =
string "tmp;",
newline,
string "uw_error(ctx, FATAL, \"",
- string (ErrorMsg.spanToString loc),
- string ": %s\", ",
+ string (if Settings.getDebug () then
+ ErrorMsg.spanToString loc ^ ": "
+ else
+ ""),
+ string "%s\", ",
p_exp' false false env e,
string ");",
newline,
@@ -3515,11 +3518,6 @@ fun p_file env (ds, ps) =
NONE => box []
| SOME n => box [string "static void uw_onError(uw_context ctx, char *msg) {",
newline,
- if Settings.getDebug () then
- box []
- else
- box [string "uw_cutErrorLocation(msg);",
- newline],
if !hasJs then
box [string "uw_set_script_header(ctx, \"",
string allScripts,