void StepController::HandleResumeAction(Js::InterpreterHaltState* haltState, BREAKRESUMEACTION resumeAction) { ResetReturnedValueList(); switch (resumeAction) { case BREAKRESUMEACTION_STEP_INTO: Activate(Js::STEP_IN, haltState); break; case BREAKRESUMEACTION_STEP_OVER: Activate(Js::STEP_OVER, haltState); break; case BREAKRESUMEACTION_STEP_OUT: Activate(Js::STEP_OUT, haltState); break; case BREAKRESUMEACTION_STEP_DOCUMENT: Activate(Js::STEP_DOCUMENT, haltState); break; } }
void StepController::Deactivate(InterpreterHaltState* haltState /*=nullptr*/) { // If we are deactivating the step controller during ProbeContainer close or attach/detach we should clear return value list // If we break other than step -> clear the list. // If we step in and we land on different function (we are in recording phase the current function) -> clear the list if ((haltState == nullptr) || (haltState->stopType != Js::STOP_STEPCOMPLETE || (this->stepType == STEP_IN && this->returnedValueRecordingDepth > 0))) { ResetReturnedValueList(); } if (this->body) { Assert(this->pActivatedContext); this->body.Unroot(this->pActivatedContext->GetRecycler()); } this->pActivatedContext = NULL; stepType = STEP_NONE; byteOffset = Js::Constants::NoByteCodeOffset; statementMap = NULL; frameCountWhenSet = 0; scriptIdWhenSet = InvalidScriptId; frameAddrWhenSet = (size_t)-1; }