fixed initialization of hcl->nil_process

got rid of HCL_CODE_MAKE_CLASS and merged its feature to HCL_CODE_CLASS_ENTER
This commit is contained in:
2021-06-25 16:07:29 +00:00
parent 2fbb2eda6c
commit 2f2baf2f59
5 changed files with 69 additions and 73 deletions

View File

@ -813,7 +813,16 @@ int hcl_ignite (hcl_t* hcl, hcl_oow_t heapsize)
* only accessible by VM. not exported via the global dictionary. */
hcl->nil_process = (hcl_oop_process_t)hcl_allocoopobj(hcl, HCL_BRAND_PROCESS, HCL_PROCESS_NAMED_INSTVARS);
if (HCL_UNLIKELY(!hcl->nil_process)) return -1;
/* unusable stack */
hcl->nil_process->sp = HCL_SMOOI_TO_OOP(-1);
hcl->nil_process->st = HCL_SMOOI_TO_OOP(-1);
/* unusable exception stack */
hcl->nil_process->exsp = HCL_SMOOI_TO_OOP(-1);
hcl->nil_process->exst = HCL_SMOOI_TO_OOP(-1);
/* unusable class stack */
hcl->nil_process->clsp = HCL_SMOOI_TO_OOP(-1);
hcl->nil_process->clst = HCL_SMOOI_TO_OOP(-1);
}
if (!hcl->processor)