mirror of
https://github.com/odin-lang/Odin.git
synced 2026-10-13 12:36:36 -04:00
Allow .allocator for dynamic arrays; Add mem.Pool
This commit is contained in:
1 parent
915dcb0c28
commit
e9e7ce2606
8 files changed
+253
-142
No files matched your search
@@ -2648,6 +2648,9 @@ Entity *check_selector(CheckerContext *c, Operand *operand, AstNode *node, Type
|
||||
|
||||
if (entity == nullptr && selector->kind == AstNode_Ident) {
|
||||
String field_name = selector->Ident.token.string;
|
||||
if (is_type_dynamic_array(type_deref(operand->type))) {
|
||||
init_mem_allocator(c->checker);
|
||||
}
|
||||
sel = lookup_field(operand->type, field_name, operand->mode == Addressing_Type);
|
||||
entity = sel.entity;
|
||||
|
||||
|
||||
Reference in new issue
Block a user