diff options
author | S.H <[email protected]> | 2021-10-03 22:34:45 +0900 |
---|---|---|
committer | GitHub <[email protected]> | 2021-10-03 22:34:45 +0900 |
commit | dc9112cf10e63b5272e9469d080d5d1ced30276e (patch) | |
tree | 2970b172b25b303dd839fced592564a77eedeab1 /vm_backtrace.c | |
parent | fb03598666ddbb9f8b35eb4f599e75654ca7ca06 (diff) |
Using NIL_P macro instead of `== Qnil`
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/4925
Merged-By: nobu <[email protected]>
Diffstat (limited to 'vm_backtrace.c')
-rw-r--r-- | vm_backtrace.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/vm_backtrace.c b/vm_backtrace.c index fc9f701d09..8294d218a4 100644 --- a/vm_backtrace.c +++ b/vm_backtrace.c @@ -1495,7 +1495,7 @@ rb_profile_frames(int start, int limit, VALUE *buff, int *lines) static const rb_iseq_t * frame2iseq(VALUE frame) { - if (frame == Qnil) return NULL; + if (NIL_P(frame)) return NULL; if (RB_TYPE_P(frame, T_IMEMO)) { switch (imemo_type(frame)) { @@ -1528,7 +1528,7 @@ rb_profile_frame_path(VALUE frame) static const rb_callable_method_entry_t * cframe(VALUE frame) { - if (frame == Qnil) return NULL; + if (NIL_P(frame)) return NULL; if (RB_TYPE_P(frame, T_IMEMO)) { switch (imemo_type(frame)) { @@ -1589,7 +1589,7 @@ rb_profile_frame_first_lineno(VALUE frame) static VALUE frame2klass(VALUE frame) { - if (frame == Qnil) return Qnil; + if (NIL_P(frame)) return Qnil; if (RB_TYPE_P(frame, T_IMEMO)) { const rb_callable_method_entry_t *cme = (rb_callable_method_entry_t *)frame; |