debugger support

This commit is contained in:
Jeff Hutchinson 2021-08-19 22:05:43 -04:00
parent 98a2fa0f33
commit 59312d7d52
8 changed files with 46 additions and 15 deletions

View file

@ -710,7 +710,7 @@ void ExprEvalState::pushFrame(StringTableEntry frameName, Namespace *ns, S32 reg
AssertFatal(!newFrame.getCount(), "ExprEvalState::pushFrame - Dictionary not empty!");
ConsoleValue* consoleValArray = new ConsoleValue[registerCount];
ConsoleValue* consoleValArray = new ConsoleValue[registerCount]();
localStack.push_back(ConsoleValueFrame(consoleValArray, false));
currentRegisterArray = &localStack.last();
@ -787,6 +787,19 @@ void ExprEvalState::pushFrameRef(S32 stackIndex)
#endif
}
void ExprEvalState::pushDebugFrame(S32 stackIndex)
{
pushFrameRef(stackIndex);
Dictionary& newFrame = *(stack[mStackDepth - 1]);
// debugger needs to know this info...
newFrame.scopeName = stack[stackIndex]->scopeName;
newFrame.scopeNamespace = stack[stackIndex]->scopeNamespace;
newFrame.code = stack[stackIndex]->code;
newFrame.ip = stack[stackIndex]->ip;
}
ExprEvalState::ExprEvalState()
{
VECTOR_SET_ASSOCIATION(stack);