[sledge] Improve uncaught exceptions

Summary:
Do not implicitly open `Trace`, which shadows `Import.fail`, and
degrades uncaught exceptions. Opening `Trace` was a mistake.

Reviewed By: kren1

Differential Revision: D15653730

fbshipit-source-id: d65277af5
master
Josh Berdine 6 years ago committed by Facebook Github Bot
parent 6a2da2acc4
commit 4ea2cf9814

@ -33,4 +33,4 @@ let find key = Yojson.Basic.Util.(to_string_option (member key contents))
let find_exn key = let find_exn key =
match find key with match find key with
| Some data -> data | Some data -> data
| None -> fail "%s not specified in config file %s" key config_file | None -> fail "%s not specified in config file %s" key config_file ()

@ -6,7 +6,7 @@
* LICENSE file in the root directory of this source tree. * LICENSE file in the root directory of this source tree.
*) *)
let deps = ["import"; "trace"; "llair_"; "symbheap"] let deps = ["import"; "llair_"; "symbheap"]
;; ;;
Jbuild_plugin.V1.send Jbuild_plugin.V1.send

@ -6,7 +6,7 @@
* LICENSE file in the root directory of this source tree. * LICENSE file in the root directory of this source tree.
*) *)
let deps = ["import"; "trace"; "llair_"] let deps = ["import"; "llair_"]
;; ;;
Jbuild_plugin.V1.send Jbuild_plugin.V1.send

@ -9,7 +9,7 @@ let%test_module _ =
( module struct ( module struct
open Equality open Equality
let () = Trace.init ~margin:68 ~config:none () let () = Trace.init ~margin:68 ~config:Trace.none ()
(* let () = Trace.init ~margin:160 ~config:all () *) (* let () = Trace.init ~margin:160 ~config:all () *)
let printf pp = Format.printf "@\n%a@." pp let printf pp = Format.printf "@\n%a@." pp

@ -9,7 +9,7 @@ let%test_module _ =
( module struct ( module struct
(* let () = Trace.init ~margin:68 ~config:all () *) (* let () = Trace.init ~margin:68 ~config:all () *)
let () = Trace.init ~margin:68 ~config:none () let () = Trace.init ~margin:68 ~config:Trace.none ()
let pp = Format.printf "@\n%a@." Sh.pp let pp = Format.printf "@\n%a@." Sh.pp
let pp_djn = Format.printf "@\n%a@." Sh.pp_djn let pp_djn = Format.printf "@\n%a@." Sh.pp_djn
let ( ~$ ) = Var.Set.of_list let ( ~$ ) = Var.Set.of_list

Loading…
Cancel
Save