File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3002,8 +3002,6 @@ rb_gc_mark_children(void *objspace, VALUE obj)
30023002 }
30033003
30043004 case T_OBJECT : {
3005- rb_shape_t * shape = RSHAPE (ROBJECT_SHAPE_ID (obj ));
3006-
30073005 if (rb_shape_obj_too_complex_p (obj )) {
30083006 gc_mark_tbl_no_pin (ROBJECT_FIELDS_HASH (obj ));
30093007 }
@@ -3016,13 +3014,13 @@ rb_gc_mark_children(void *objspace, VALUE obj)
30163014 }
30173015 }
30183016
3019- if (shape ) {
3017+ attr_index_t fields_count = ROBJECT_FIELDS_COUNT (obj );
3018+ if (fields_count ) {
30203019 VALUE klass = RBASIC_CLASS (obj );
30213020
30223021 // Increment max_iv_count if applicable, used to determine size pool allocation
3023- attr_index_t num_of_ivs = shape -> next_field_index ;
3024- if (RCLASS_EXT (klass )-> max_iv_count < num_of_ivs ) {
3025- RCLASS_EXT (klass )-> max_iv_count = num_of_ivs ;
3022+ if (RCLASS_EXT (klass )-> max_iv_count < fields_count ) {
3023+ RCLASS_EXT (klass )-> max_iv_count = fields_count ;
30263024 }
30273025 }
30283026
You can’t perform that action at this time.
0 commit comments