added a test on process handling.
Some checks failed
continuous-integration/drone/push Build is failing

used hcl_instantiate() in making process-related objects
This commit is contained in:
2024-09-12 16:08:16 +09:00
parent 8604c6ddf1
commit 6e9e1d35f4
10 changed files with 113 additions and 54 deletions

View File

@ -173,14 +173,8 @@ hcl_oop_t hcl_allocoopobjwithtrailer (hcl_t* hcl, int brand, hcl_oow_t size, con
/* [NOTE] this is not converted to a SMOOI object */
hdr->slot[size] = (hcl_oop_t)blen;
if (bptr)
{
HCL_MEMCPY (&hdr->slot[size + 1], bptr, blen);
}
else
{
HCL_MEMSET (&hdr->slot[size + 1], 0, blen);
}
if (bptr) HCL_MEMCPY (&hdr->slot[size + 1], bptr, blen);
else HCL_MEMSET (&hdr->slot[size + 1], 0, blen);
return (hcl_oop_t)hdr;
}
@ -224,7 +218,7 @@ static HCL_INLINE hcl_oop_t alloc_numeric_array (hcl_t* hcl, int brand, const vo
else
{
/* initialize with zeros when the string pointer is not given */
HCL_MEMSET ((hdr + 1), 0, nbytes_aligned);
HCL_MEMSET (hdr + 1, 0, nbytes_aligned);
}
return hdr;