From 4772066c996b78e1c1c8694813adadfeed5b21fc Mon Sep 17 00:00:00 2001 From: Jeremy Woertink Date: Wed, 25 Dec 2024 14:19:38 -0800 Subject: [PATCH] Deprecate `Process::Status#exit_status` (#8647) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Johannes Müller --- src/process/status.cr | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/process/status.cr b/src/process/status.cr index 933e81d5ad84..268d2f9e52d6 100644 --- a/src/process/status.cr +++ b/src/process/status.cr @@ -104,6 +104,7 @@ end class Process::Status # Platform-specific exit status code, which usually contains either the exit code or a termination signal. # The other `Process::Status` methods extract the values from `exit_status`. + @[Deprecated("Use `#exit_reason`, `#exit_code`, or `#system_exit_status` instead")] def exit_status : Int32 @exit_status.to_i32! end @@ -268,7 +269,7 @@ class Process::Status # define __WEXITSTATUS(status) (((status) & 0xff00) >> 8) (@exit_status & 0xff00) >> 8 {% else %} - exit_status + @exit_status.to_i32! {% end %} end