Removed useless casts

This commit is contained in:
Nobuyoshi Nakada 2020-09-05 17:28:06 +09:00
parent 72757fb596
commit 5c49bb5486
No known key found for this signature in database
GPG Key ID: 7CD2805BFA3770C6

View File

@ -1503,13 +1503,12 @@ r_string(struct load_arg *arg)
static VALUE static VALUE
r_entry0(VALUE v, st_index_t num, struct load_arg *arg) r_entry0(VALUE v, st_index_t num, struct load_arg *arg)
{ {
st_data_t real_obj = (VALUE)Qundef; st_data_t real_obj = (st_data_t)v;
if (arg->compat_tbl && st_lookup(arg->compat_tbl, v, &real_obj)) { if (arg->compat_tbl) {
st_insert(arg->data, num, (st_data_t)real_obj); /* real_obj is kept if not found */
} st_lookup(arg->compat_tbl, v, &real_obj);
else {
st_insert(arg->data, num, (st_data_t)v);
} }
st_insert(arg->data, num, real_obj);
return v; return v;
} }