diff options
author | Peter Zhu <[email protected]> | 2024-12-16 11:02:12 -0500 |
---|---|---|
committer | Peter Zhu <[email protected]> | 2024-12-16 13:32:35 -0500 |
commit | d28368d27f6ee8e82dc293f10cbbcbe7f07fa9d1 (patch) | |
tree | d525be6182b54ff114ac1cc12bdc3b32102c1bec /gc.c | |
parent | d0968b1b4c402a355f207db10abbb067ee3d3377 (diff) |
Move special constant check in rb_gc_location to gc.c
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/12359
Diffstat (limited to 'gc.c')
-rw-r--r-- | gc.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -3150,6 +3150,10 @@ check_id_table_move(VALUE value, void *data) VALUE rb_gc_location(VALUE value) { + if (SPECIAL_CONST_P(value)) { + return value; + } + return rb_gc_impl_location(rb_gc_get_objspace(), value); } |