MCPcopy Create free account
hub / github.com/AutoHotkey/AutoHotkey / Push

Method Push

source/Debugger.cpp:2680–2697  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2678
2679
2680DbgStack::Entry *DbgStack::Push()
2681{
2682 if (mTop == mTopBound)
2683 Expand();
2684 if (mTop >= mBottom)
2685 {
2686 // Whenever this entry != mTop, Entry::line is used instead of g_Debugger.mCurrLine,
2687 // which means that it needs to point to the last executed line at that depth. The
2688 // following fixes a bug where the line number of this entry appears to revert to
2689 // the first line of the function or sub whenever the debugger steps into another
2690 // function or sub. Entry::line is also used by Object::Error__New even when the
2691 // debugger is disconnected, which has two consequences:
2692 // - g_script.mCurrLine must be used in place of g_Debugger.mCurrLine.
2693 // - Changing PreExecLine() to update mStack.mTop->line won't help.
2694 mTop->line = g_script.mCurrLine;
2695 }
2696 return ++mTop;
2697}
2698
2699void DbgStack::Push(TCHAR *aDesc)
2700{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected