src/Pure/System/command_line.ML
changeset 78673 90b12b919b5f
parent 78671 66e7a3131fe3
child 78716 97dfba4405e3
--- a/src/Pure/System/command_line.ML	Tue Sep 19 13:12:13 2023 +0200
+++ b/src/Pure/System/command_line.ML	Tue Sep 19 13:46:11 2023 +0200
@@ -15,11 +15,9 @@
 fun tool body =
   Thread_Attributes.uninterruptible (fn restore_attributes => fn () =>
     let
-      fun return_code exn =
-        if Exn.is_interrupt exn then 130 else 2;
       val rc =
         (restore_attributes body (); 0) handle exn =>
-          ((Runtime.exn_error_message exn; return_code exn) handle err => return_code err);
+          ((Runtime.exn_error_message exn; Exn.failure_rc exn) handle err => Exn.failure_rc err);
     in exit rc end) ();
 
 end;