Include the ivar in the Objective-C class unconditionally of it being used or not.

Allow pseudo-fields for ivar access.
This commit is contained in:
Harold Brenes
2025-04-22 19:16:29 -04:00
parent b3b4d501ca
commit bca02f81cd
4 changed files with 54 additions and 25 deletions

View File

@@ -3329,6 +3329,15 @@ gb_internal Selection lookup_field_with_selection(Type *type_, String field_name
}
}
}
Type *objc_ivar_type = e->TypeName.objc_ivar;
if (objc_ivar_type != nullptr) {
sel = lookup_field_with_selection(objc_ivar_type, field_name, false, sel, allow_blank_ident);
if (sel.entity != nullptr) {
sel.pseudo_field = true;
return sel;
}
}
}
if (is_type_polymorphic(type)) {