Browse Source

Use VmCreateMemObj() to create $this.

release/v0.1
Rafal Kupiec 1 year ago
parent
commit
3dfa4232ba
Signed by: belliash GPG Key ID: 4E829243E0CFE6B4
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      engine/vm.c

+ 1
- 1
engine/vm.c View File

@ -4610,7 +4610,7 @@ static sxi32 VmByteCodeExec(
if((pVmFunc->iFlags & VM_FUNC_CLASS_METHOD) && pThis) {
/* Install the '$this' variable */
static const SyString sThis = { "this", sizeof("this") - 1 };
pObj = VmExtractMemObj(&(*pVm), &sThis, FALSE, TRUE);
pObj = VmCreateMemObj(&(*pVm), &sThis, FALSE);
if(pObj) {
/* Reflect the change */
pObj->x.pOther = pThis;

Loading…
Cancel
Save