Enable garbage collector for Program class. This also partially fixes #47, as from now Program::__destruct() will be called automatically.
The build was successful.
Details
The build was successful.
Details
This commit is contained in:
parent
b60c1de4cf
commit
3d23d43040
|
@ -5472,6 +5472,8 @@ PH7_PRIVATE sxi32 PH7_VmByteCodeExec(ph7_vm *pVm) {
|
|||
if(pInstance == 0) {
|
||||
PH7_VmMemoryError(&(*pVm));
|
||||
}
|
||||
/* Enable garbage collector */
|
||||
pInstance->iRef--;
|
||||
/* Check if a constructor is available */
|
||||
pMethod = PH7_ClassExtractMethod(pClass, "__construct", sizeof("__construct") - 1);
|
||||
if(pMethod) {
|
||||
|
|
Loading…
Reference in New Issue