Skip to content

Commit

Permalink
Deprecate Process::Status#exit_status
Browse files Browse the repository at this point in the history
  • Loading branch information
oprypin committed Apr 13, 2020
1 parent 10982fe commit cef5b0a
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/process/status.cr
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
# The status of a terminated process. Returned by `Process#wait`.
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`.
def exit_status : Int32
@exit_status.to_i32!
end

{% if flag?(:win32) %}
# :nodoc:
def initialize(@exit_status : UInt32)
Expand Down Expand Up @@ -74,4 +68,10 @@ class Process::Status
# define __WTERMSIG(status) ((status) & 0x7f)
@exit_status & 0x7f
end

# Platform-specific exit status code, which usually contains either the exit code or a termination signal.
@[Deprecated("Use `Process::Status#exit_code`")]
def exit_status : Int32
@exit_status.to_i32!
end
end

0 comments on commit cef5b0a

Please sign in to comment.