/* * call-seq: * stat & num => fixnum * * Logical AND of the bits in _stat_ with <em>num</em>. * * fork { exit 0x37 } * Process.wait * sprintf('%04x', $?.to_i) #=> "3700" * sprintf('%04x', $? & 0x1e00) #=> "1600" */ static VALUE pst_bitand(st1, st2) VALUE st1, st2; { int status = NUM2INT(st1) & NUM2INT(st2); return INT2NUM(status); }