summaryrefslogtreecommitdiff
path: root/iseq.c
diff options
context:
space:
mode:
authormame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-13 12:44:17 +0000
committermame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-13 12:44:17 +0000
commit7ad9975fe7e8e22de841b26ed549652326d08c65 (patch)
tree673600ac2e387fb3164c8480164d5a4a70f776a0 /iseq.c
parent879df66d96ea7d822de2ea06602a1bba0ee5cb52 (diff)
iseq.h (struct iseq_catch_table_entry, iseq_compile_data_storage): Use FLEX_ARY_LEN
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61808 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'iseq.c')
-rw-r--r--iseq.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/iseq.c b/iseq.c
index ee49026c9a..57ff506d0a 100644
--- a/iseq.c
+++ b/iseq.c
@@ -208,7 +208,7 @@ iseq_memsize(const rb_iseq_t *iseq)
cur = compile_data->storage_head;
while (cur) {
- size += cur->size + SIZEOF_ISEQ_COMPILE_DATA_STORAGE;
+ size += cur->size + sizeof(struct iseq_compile_data_storage);
cur = cur->next;
}
}
@@ -333,7 +333,7 @@ prepare_iseq_build(rb_iseq_t *iseq,
ISEQ_COMPILE_DATA(iseq)->storage_head = ISEQ_COMPILE_DATA(iseq)->storage_current =
(struct iseq_compile_data_storage *)
ALLOC_N(char, INITIAL_ISEQ_COMPILE_DATA_STORAGE_BUFF_SIZE +
- SIZEOF_ISEQ_COMPILE_DATA_STORAGE);
+ sizeof(struct iseq_compile_data_storage));
RB_OBJ_WRITE(iseq, &ISEQ_COMPILE_DATA(iseq)->catch_table_ary, rb_ary_tmp_new(3));
ISEQ_COMPILE_DATA(iseq)->storage_head->pos = 0;