mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-06 15:48:51 +00:00
Fix indirect selector bug with using on offset_of
This commit is contained in:
@@ -2457,6 +2457,7 @@ Selection lookup_field_with_selection(Type *type_, String field_name, bool is_ty
|
|||||||
|
|
||||||
if (f->flags & EntityFlag_Using) {
|
if (f->flags & EntityFlag_Using) {
|
||||||
isize prev_count = sel.index.count;
|
isize prev_count = sel.index.count;
|
||||||
|
bool prev_indirect = sel.indirect;
|
||||||
selection_add_index(&sel, i); // HACK(bill): Leaky memory
|
selection_add_index(&sel, i); // HACK(bill): Leaky memory
|
||||||
|
|
||||||
sel = lookup_field_with_selection(f->type, field_name, is_type, sel, allow_blank_ident);
|
sel = lookup_field_with_selection(f->type, field_name, is_type, sel, allow_blank_ident);
|
||||||
@@ -2468,6 +2469,7 @@ Selection lookup_field_with_selection(Type *type_, String field_name, bool is_ty
|
|||||||
return sel;
|
return sel;
|
||||||
}
|
}
|
||||||
sel.index.count = prev_count;
|
sel.index.count = prev_count;
|
||||||
|
sel.indirect = prev_indirect;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user