Method: Process::Status#==

Defined in:
process.c

#==(other) ⇒ Boolean

Returns whether the value of #to_i == other:

`cat /nop`
stat = $?                # => #<Process::Status: pid 1170366 exit 1>
sprintf('%x', stat.to_i) # => "100"
stat == 0x100            # => true

Returns:

  • (Boolean)


868
869
870
871
872
873
# File 'process.c', line 868

static VALUE
pst_equal(VALUE st1, VALUE st2)
{
    if (st1 == st2) return Qtrue;
    return rb_equal(pst_to_i(st1), st2);
}