changed the object instantiation function to add up the instance variables counts of the superclass chain

This commit is contained in:
2022-02-07 15:13:38 +00:00
parent ef24bf68df
commit 2c2cfc99bb
3 changed files with 32 additions and 25 deletions

View File

@ -387,7 +387,7 @@ static HCL_INLINE int decode_spec (hcl_t* hcl, hcl_oop_class_t _class, hcl_obj_t
/* TODO: */
*type = HCL_OBJ_TYPE_OOP;
*outlen = HCL_OOP_TO_SMOOI(_class->nivars);
*outlen = HCL_OOP_TO_SMOOI(_class->nivars_super) + HCL_OOP_TO_SMOOI(_class->nivars);
return 0;
}