Skip to content

Stop at breakpoints on a function's initial statements#405

Merged
KristofferC merged 2 commits into
masterfrom
kc/first-statement-breakpoint
Jul 18, 2026
Merged

Stop at breakpoints on a function's initial statements#405
KristofferC merged 2 commits into
masterfrom
kc/first-statement-breakpoint

Conversation

@KristofferC

Copy link
Copy Markdown
Member

Two places used to skip breakpoints set on a function's first statement(s):

  • @make_frame advanced to the first call with maybe_next_call!, executing any breakpointed non-call statement on the way.
  • @run unconditionally executed c, which steps over a breakpoint on the statement the frame is already stopped at, so a breakpoint on the first statement never fired and @run ran to completion.

Now @make_frame advances with a predicate that also stops at breakpointed statements, and @run skips the initial c when the entry statement has a breakpoint, showing the prompt there instead.

Reimplements #148 by @pfitzseb on current master. Adds a unit test and a UI regression test.

Fixes #134
Closes #148

🤖 Generated with Claude Code

KristofferC and others added 2 commits July 18, 2026 14:02
Two places used to skip such breakpoints:

- `@make_frame` advanced to the first call with `maybe_next_call!`,
  executing any breakpointed non-call statement before it.
- `@run` unconditionally executed `c`, which steps over a breakpoint
  on the statement the frame is already stopped at, so a breakpoint on
  the first statement never fired.

Reimplements #148 by pfitzseb on current master.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@KristofferC
KristofferC merged commit cc76f49 into master Jul 18, 2026
12 checks passed
@KristofferC
KristofferC deleted the kc/first-statement-breakpoint branch July 18, 2026 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Don't skip any initial stuff with @run

1 participant