Skip to content

Commit

Permalink
Remove deprecated code to fix RUBY_DEBUG build failures
Browse files Browse the repository at this point in the history
  • Loading branch information
k0kubun committed Dec 25, 2023
1 parent 44592c4 commit 9614bea
Showing 1 changed file with 0 additions and 36 deletions.
36 changes: 0 additions & 36 deletions process.c
Expand Up @@ -900,27 +900,6 @@ pst_bitand(VALUE st1, VALUE st2)
if (mask < 0) {
rb_raise(rb_eArgError, "negative mask value: %d", mask);
}
#define WARN_SUGGEST(suggest) \
rb_warn_deprecated_to_remove_at(3.4, "Process::Status#&", suggest)

switch (mask) {
case 0x80:
WARN_SUGGEST("Process::Status#coredump?");
break;
case 0x7f:
WARN_SUGGEST("Process::Status#signaled? or Process::Status#termsig");
break;
case 0xff:
WARN_SUGGEST("Process::Status#exited?, Process::Status#stopped? or Process::Status#coredump?");
break;
case 0xff00:
WARN_SUGGEST("Process::Status#exitstatus or Process::Status#stopsig");
break;
default:
WARN_SUGGEST("other Process::Status predicates");
break;
}
#undef WARN_SUGGEST
status &= mask;

return INT2NUM(status);
Expand Down Expand Up @@ -955,21 +934,6 @@ pst_rshift(VALUE st1, VALUE st2)
if (places < 0) {
rb_raise(rb_eArgError, "negative shift value: %d", places);
}
#define WARN_SUGGEST(suggest) \
rb_warn_deprecated_to_remove_at(3.4, "Process::Status#>>", suggest)

switch (places) {
case 7:
WARN_SUGGEST("Process::Status#coredump?");
break;
case 8:
WARN_SUGGEST("Process::Status#exitstatus or Process::Status#stopsig");
break;
default:
WARN_SUGGEST("other Process::Status attributes");
break;
}
#undef WARN_SUGGEST
status >>= places;

return INT2NUM(status);
Expand Down

0 comments on commit 9614bea

Please sign in to comment.