- if is_constant p.div\r
- then print_endline "!!! div is stuck. Problem was not run !!!"\r
- else if eta_subterm p.div p.conv\r
- then print_endline "!!! div is subterm of conv. Problem was not run !!!"\r
- else let p = sanity p (* initial sanity check *) in check p (auto p)\r
+ let c = if String.length p.label > 0 then String.sub (p.label) 0 1 else "" in\r
+ let module M = struct exception Okay end in\r
+ try\r
+ if eta_subterm p.div p.conv\r
+ then raise (Unseparable "div is subterm of conv")\r
+ else\r
+ let p = sanity p (* initial sanity check *) in\r
+ check p (auto p);\r
+ raise M.Okay\r
+ with\r
+ | M.Okay -> if c = "?" then\r
+ failwith "The problem succeeded, but was supposed to be unseparable"\r
+ | e when c = "!" ->\r
+ failwith ("The problem was supposed to be separable, but: "^Printexc.to_string e)\r
+ | e ->\r
+ print_endline ("The problem failed, as expected ("^Printexc.to_string e^")")\r