Another fix in debug trace.
All checks were successful
The build was successful.

This commit is contained in:
Rafal Kupiec 2018-09-14 22:22:37 +02:00
parent 94ae7d187b
commit faca9b7fb2
Signed by: belliash
GPG Key ID: 4E829243E0CFE6B4
2 changed files with 18 additions and 16 deletions

View File

@ -1733,6 +1733,7 @@ PH7_PRIVATE sxi32 VmExtractDebugTrace(ph7_vm *pVm, SySet *pDebugTrace) {
break; break;
} }
} }
if(aTrace.pFile) {
aTrace.pClassName = NULL; aTrace.pClassName = NULL;
aTrace.bThis = FALSE; aTrace.bThis = FALSE;
if(pFunc->iFlags & VM_FUNC_CLASS_METHOD) { if(pFunc->iFlags & VM_FUNC_CLASS_METHOD) {
@ -1751,6 +1752,7 @@ PH7_PRIVATE sxi32 VmExtractDebugTrace(ph7_vm *pVm, SySet *pDebugTrace) {
break; break;
} }
} }
}
/* Roll frame */ /* Roll frame */
pVm->pFrame = pVm->pFrame->pParent; pVm->pFrame = pVm->pFrame->pParent;
} }

View File

@ -1231,7 +1231,7 @@ struct ph7_vm {
int nMaxDepth; /* Maximum allowed recursion depth */ int nMaxDepth; /* Maximum allowed recursion depth */
int nExceptDepth; /* Exception depth */ int nExceptDepth; /* Exception depth */
int closure_cnt; /* Loaded closures counter */ int closure_cnt; /* Loaded closures counter */
int json_rc; /* JSON return status [refer to json_encode()/json_decode()]*/ int json_rc; /* JSON return status [refer to json_encode()/json_decode()] */
ph7_output_consumer sVmConsumer; /* Registered output consumer callback */ ph7_output_consumer sVmConsumer; /* Registered output consumer callback */
int iAssertFlags; /* Assertion flags */ int iAssertFlags; /* Assertion flags */
ph7_value sAssertCallback; /* Callback to call on failed assertions */ ph7_value sAssertCallback; /* Callback to call on failed assertions */
@ -1258,7 +1258,7 @@ struct VmFrame {
SyHash hVar; /* Variable hashtable for fast lookup */ SyHash hVar; /* Variable hashtable for fast lookup */
SySet sArg; /* Function arguments container */ SySet sArg; /* Function arguments container */
SySet sRef; /* Local reference table (VmSlot instance) */ SySet sRef; /* Local reference table (VmSlot instance) */
sxi32 iFlags; /* Frame configuration flags (See below)*/ sxi32 iFlags; /* Frame configuration flags (See below) */
sxu32 iExceptionJump; /* Exception jump destination */ sxu32 iExceptionJump; /* Exception jump destination */
}; };
#define VM_FRAME_EXCEPTION 0x01 /* Special Exception frame */ #define VM_FRAME_EXCEPTION 0x01 /* Special Exception frame */