a code review tool

fix: catch top-level exceptions in main entry point

+7 -1
+7 -1
bin/main.ml
··· 1 1 let () = 2 - match Lwt_main.run (Lens_tui.main ()) with 2 + let result = 3 + try Lwt_main.run (Lens_tui.main ()) with 4 + | exn -> 5 + Printf.eprintf "Fatal: %s\n" (Printexc.to_string exn); 6 + exit 1 7 + in 8 + match result with 3 9 | Ok () -> () 4 10 | Error err -> 5 11 Printf.eprintf "Error: %s\n" (Core.Error.to_string_hum err);