fix(debugger): Step Out no longer stops mid-epilogue on its own RETURN record - #22
Open
geircodes wants to merge 1 commit into
Open
fix(debugger): Step Out no longer stops mid-epilogue on its own RETURN record#22geircodes wants to merge 1 commit into
geircodes wants to merge 1 commit into
Conversation
…N record A Clarion procedure's frame teardown (mov esp,ebp / pop ebp / ret) is several instructions all mapped to the SAME RETURN-statement record, and the esp growth from the first of them alone was enough to satisfy Out's old stop condition before the actual `ret` had run — causing Step Out to stop repeatedly on its own epilogue instead of reaching the caller. Out now also requires newStatement (leaving the starting record), the same guard Into/Over already use. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A Clarion procedure's frame teardown (
mov esp,ebp/pop ebp/ret) is several instructions all mapped to the SAME RETURN-statement record. The old stop condition forStepMode.Out(esp > _startEsp && gap <= OUT_GAP_MAX) only checked that esp had grown past the start — the first epilogue instruction alone already satisfies that, before the actualrethas run. Result: pressing Step Out from (or near) a procedure's own RETURN/END line repeatedly re-stops on that same procedure's epilogue instead of reaching the caller; you have to fall back to a plain Step to actually leave.Fix:
Outnow also requiresnewStatement(leaving the starting record) — the same guardInto/Overalready use.Verified live: set a breakpoint on a RETURN line, pressed Step Out repeatedly — before the fix it stopped again on the same line every time; after, it goes straight to the caller's next statement.