[前][次][番号順一覧][スレッド一覧]

ruby-changes:74491

From: Peter <ko1@a...>
Date: Tue, 15 Nov 2022 01:25:57 +0900 (JST)
Subject: [ruby-changes:74491] 6dd1a5f532 (master): Remove unused function rb_shape_transition_shape

https://git.ruby-lang.org/ruby.git/commit/?id=6dd1a5f532

From 6dd1a5f532711a28ffe815455503f5a2b1f70d23 Mon Sep 17 00:00:00 2001
From: Peter Zhu <peter@p...>
Date: Fri, 11 Nov 2022 10:37:11 -0500
Subject: Remove unused function rb_shape_transition_shape

---
 shape.c | 10 ----------
 shape.h |  1 -
 2 files changed, 11 deletions(-)

diff --git a/shape.c b/shape.c
index b20ac10a14..66f5f69a0c 100644
--- a/shape.c
+++ b/shape.c
@@ -212,16 +212,6 @@ rb_shape_transition_shape_frozen(VALUE obj) https://github.com/ruby/ruby/blob/trunk/shape.c#L212
     rb_shape_set_shape(obj, next_shape);
 }
 
-void
-rb_shape_transition_shape(VALUE obj, ID id, rb_shape_t *shape)
-{
-    rb_shape_t* next_shape = rb_shape_get_next(shape, obj, id);
-    if (shape == next_shape) {
-        return;
-    }
-    rb_shape_set_shape(obj, next_shape);
-}
-
 /*
  * This function is used for assertions where we don't want to increment
  * max_iv_count
diff --git a/shape.h b/shape.h
index 417a013697..a2cbd7c482 100644
--- a/shape.h
+++ b/shape.h
@@ -144,7 +144,6 @@ int rb_shape_frozen_shape_p(rb_shape_t* shape); https://github.com/ruby/ruby/blob/trunk/shape.h#L144
 void rb_shape_transition_shape_frozen(VALUE obj);
 void rb_shape_transition_shape_remove_ivar(VALUE obj, ID id, rb_shape_t *shape);
 rb_shape_t * rb_shape_transition_shape_capa(rb_shape_t * shape, uint32_t new_capacity);
-void rb_shape_transition_shape(VALUE obj, ID id, rb_shape_t *shape);
 rb_shape_t * rb_shape_get_next_iv_shape(rb_shape_t * shape, ID id);
 rb_shape_t* rb_shape_get_next(rb_shape_t* shape, VALUE obj, ID id);
 bool rb_shape_get_iv_index(rb_shape_t * shape, ID id, attr_index_t * value);
-- 
cgit v1.2.3


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]