зеркало из https://github.com/github/ruby.git
Remove useless casts
This commit is contained in:
Родитель
fae44d6524
Коммит
e824b69a86
|
@ -719,7 +719,7 @@ pm_lookup_local_index_with_depth(rb_iseq_t *iseq, pm_scope_node_t *scope_node, p
|
|||
static ID
|
||||
pm_constant_id_lookup(pm_scope_node_t *scope_node, pm_constant_id_t constant_id)
|
||||
{
|
||||
return ((ID *)scope_node->constants)[constant_id - 1];
|
||||
return scope_node->constants[constant_id - 1];
|
||||
}
|
||||
|
||||
static rb_iseq_t *
|
||||
|
@ -3782,7 +3782,7 @@ rb_translate_prism(pm_parser_t *parser, rb_iseq_t *iseq, pm_scope_node_t *scope_
|
|||
for (size_t i = 0; i < locals->size; i++) {
|
||||
st_insert(index_lookup_table, locals->ids[i], i);
|
||||
}
|
||||
scope_node->constants = (void *)constants;
|
||||
scope_node->constants = constants;
|
||||
scope_node->index_lookup_table = index_lookup_table;
|
||||
|
||||
pm_compile_node(iseq, (pm_node_t *)scope_node, ret, scope_node->base.location.start, false, (pm_scope_node_t *)scope_node);
|
||||
|
|
Загрузка…
Ссылка в новой задаче