mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Adjust indent [ci skip]
This commit is contained in:
parent
81741690a0
commit
010d92e93d
1 changed files with 27 additions and 27 deletions
54
iseq.c
54
iseq.c
|
@ -118,40 +118,40 @@ iseq_clear_ic_references_i(VALUE *code, VALUE insn, size_t index, void *data)
|
||||||
struct iseq_clear_ic_references_data *ic_data = (struct iseq_clear_ic_references_data *) data;
|
struct iseq_clear_ic_references_data *ic_data = (struct iseq_clear_ic_references_data *) data;
|
||||||
|
|
||||||
switch (insn) {
|
switch (insn) {
|
||||||
case BIN(opt_getinlinecache): {
|
case BIN(opt_getinlinecache): {
|
||||||
RUBY_ASSERT_ALWAYS(ic_data->ic == NULL);
|
RUBY_ASSERT_ALWAYS(ic_data->ic == NULL);
|
||||||
|
|
||||||
ic_data->ic = (IC) code[index + 2];
|
ic_data->ic = (IC) code[index + 2];
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
case BIN(getconstant): {
|
case BIN(getconstant): {
|
||||||
if (ic_data->ic != NULL) {
|
if (ic_data->ic != NULL) {
|
||||||
ID id = (ID) code[index + 1];
|
ID id = (ID) code[index + 1];
|
||||||
rb_vm_t *vm = GET_VM();
|
rb_vm_t *vm = GET_VM();
|
||||||
VALUE lookup_result;
|
VALUE lookup_result;
|
||||||
|
|
||||||
if (rb_id_table_lookup(vm->constant_cache, id, &lookup_result)) {
|
if (rb_id_table_lookup(vm->constant_cache, id, &lookup_result)) {
|
||||||
st_table *ics = (st_table *)lookup_result;
|
st_table *ics = (st_table *)lookup_result;
|
||||||
st_data_t ic = (st_data_t)ic_data->ic;
|
st_data_t ic = (st_data_t)ic_data->ic;
|
||||||
st_delete(ics, &ic, NULL);
|
st_delete(ics, &ic, NULL);
|
||||||
|
|
||||||
if (ics->num_entries == 0) {
|
if (ics->num_entries == 0) {
|
||||||
rb_id_table_delete(vm->constant_cache, id);
|
rb_id_table_delete(vm->constant_cache, id);
|
||||||
st_free_table(ics);
|
st_free_table(ics);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
case BIN(opt_setinlinecache): {
|
|
||||||
RUBY_ASSERT_ALWAYS(ic_data->ic != NULL);
|
|
||||||
|
|
||||||
ic_data->ic = NULL;
|
return true;
|
||||||
return true;
|
}
|
||||||
}
|
case BIN(opt_setinlinecache): {
|
||||||
default:
|
RUBY_ASSERT_ALWAYS(ic_data->ic != NULL);
|
||||||
return true;
|
|
||||||
|
ic_data->ic = NULL;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
default:
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue