From 5f5b8a1fdfc71ae93f75d5bfa2d6bb2920a2f4d1 Mon Sep 17 00:00:00 2001 From: Emilio Jesus Gallego Arias Date: Thu, 30 Jan 2020 23:00:40 +0100 Subject: [exn] remove `raise` taking optional exception information argument This was redundant with `iraise`; exceptions in the logic monad now are forced to attach `info` to `Proofview.NonLogical.raise` --- engine/logic_monad.ml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'engine/logic_monad.ml') diff --git a/engine/logic_monad.ml b/engine/logic_monad.ml index 3c383b2e00..6df3378524 100644 --- a/engine/logic_monad.ml +++ b/engine/logic_monad.ml @@ -83,7 +83,7 @@ struct (** [Pervasives.raise]. Except that exceptions are wrapped with {!Exception}. *) - let raise ?info = fun e -> (); fun () -> Exninfo.raise ?info (Exception e) + let raise (e, info) () = Exninfo.iraise (Exception e, info) (** [try ... with ...] but restricted to {!Exception}. *) let catch = fun s h -> (); @@ -93,7 +93,8 @@ struct h (e, info) () let read_line = fun () -> try read_line () with e -> - let (e, info) = CErrors.push e in raise ~info e () + let (e, info) = CErrors.push e in + raise (e, info) () let print_char = fun c -> (); fun () -> print_char c -- cgit v1.2.3