summaryrefslogtreecommitdiff
path: root/toplevel
diff options
context:
space:
mode:
Diffstat (limited to 'toplevel')
-rw-r--r--toplevel/opttoploop.ml4
-rw-r--r--toplevel/opttopmain.ml2
2 files changed, 3 insertions, 3 deletions
diff --git a/toplevel/opttoploop.ml b/toplevel/opttoploop.ml
index 770ce481cf..5bac897810 100644
--- a/toplevel/opttoploop.ml
+++ b/toplevel/opttoploop.ml
@@ -325,7 +325,7 @@ let use_file ppf name =
with
| Exit -> false
| Sys.Break -> fprintf ppf "Interrupted.@."; false
- | x -> Opterrors.report_error ppf x; false) in
+ | x -> Location.report_exception ppf x; false) in
if must_close then close_in ic;
success
with Not_found -> fprintf ppf "Cannot find file %s.@." name; false
@@ -439,7 +439,7 @@ let loop ppf =
| End_of_file -> exit 0
| Sys.Break -> fprintf ppf "Interrupted.@."; Btype.backtrack snap
| PPerror -> ()
- | x -> Opterrors.report_error ppf x; Btype.backtrack snap
+ | x -> Location.report_exception ppf x; Btype.backtrack snap
done
(* Execute a script *)
diff --git a/toplevel/opttopmain.ml b/toplevel/opttopmain.ml
index 43141e8c0d..3e15c1988d 100644
--- a/toplevel/opttopmain.ml
+++ b/toplevel/opttopmain.ml
@@ -26,7 +26,7 @@ let prepare ppf =
!Opttoploop.toplevel_startup_hook ();
res
with x ->
- try Opterrors.report_error ppf x; false
+ try Location.report_exception ppf x; false
with x ->
Format.fprintf ppf "Uncaught exception: %s\n" (Printexc.to_string x);
false