summaryrefslogtreecommitdiff
path: root/iseq.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-09-03 19:48:12 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-09-03 19:48:12 +0000
commit970399a9ae739cbb4babc94159abe3b523d53d0f (patch)
tree17dcc7226fb9ede572ceddba0e9a0d07ba6db304 /iseq.c
parentebb03a0b82e6faec1941bedcdd610e68dc124ab5 (diff)
* iseq.c (iseq_memsize): functions for wrapper object should have
iseqw_ prefix. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51755 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'iseq.c')
-rw-r--r--iseq.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/iseq.c b/iseq.c
index fa89f51..c10e641 100644
--- a/iseq.c
+++ b/iseq.c
@@ -143,9 +143,8 @@ param_keyword_size(const struct rb_iseq_param_keyword *pkw)
}
static size_t
-iseq_memsize(const void *ptr)
+iseq_memsize(const rb_iseq_t *iseq)
{
- const rb_iseq_t *iseq = ptr;
size_t size = 0; /* struct already counted as RVALUE size */
const struct rb_iseq_variable_body *variable_body;
const struct rb_iseq_constant_body *body;
@@ -681,9 +680,15 @@ iseqw_mark(void *ptr)
rb_gc_mark((VALUE)ptr);
}
+static size_t
+iseqw_memsize(const void *ptr)
+{
+ return iseq_memsize((const rb_iseq_t *)ptr);
+}
+
static const rb_data_type_t iseqw_data_type = {
"T_IMEMO/iseq",
- {iseqw_mark, NULL, iseq_memsize,},
+ {iseqw_mark, NULL, iseqw_memsize,},
0, 0, RUBY_TYPED_FREE_IMMEDIATELY|RUBY_TYPED_WB_PROTECTED
};