[webkit-changes] [WebKit/WebKit] 5b1242: Web Inspector: Step Over behaves like resume when ...
Devin Rousso
noreply at github.com
Wed May 17 10:27:37 PDT 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 5b1242114ff523ce7b13e97ddb0881af98a887d6
https://github.com/WebKit/WebKit/commit/5b1242114ff523ce7b13e97ddb0881af98a887d6
Author: Devin Rousso <hi at devinrousso.com>
Date: 2023-05-17 (Wed, 17 May 2023)
Changed paths:
A LayoutTests/inspector/debugger/stepping/stepOver-breakpoint-expected.txt
A LayoutTests/inspector/debugger/stepping/stepOver-breakpoint.html
M Source/JavaScriptCore/debugger/Debugger.cpp
M Source/JavaScriptCore/debugger/Debugger.h
Log Message:
-----------
Web Inspector: Step Over behaves like resume when stepping over a function with a falsey conditional breakpoint
https://bugs.webkit.org/show_bug.cgi?id=247088
<rdar://problem/101604843>
Reviewed by Patrick Angle.
Breakpoints should only take precedence over stepping actions if they are actually triggering a pause.
If the breakpoint doesn't pause (e.g. a falsy `condition`, below the `ignoreCount`, etc.) then the `Debugger` should still behave as if it's stepping.
* Source/JavaScriptCore/debugger/Debugger.h:
* Source/JavaScriptCore/debugger/Debugger.cpp:
(JSC::Debugger::continueProgram):
(JSC::Debugger::pauseIfNeeded):
(JSC::Debugger::didExecuteProgram):
(JSC::Debugger::resetImmediatePauseState): Added.
(JSC::Debugger::resetEventualPauseState): Added.
(JSC::Debugger::clearNextPauseState): Deleted.
Split the resetting of pause state variables into two "variants":
- immediate pause state variables (e.g. "Pause script execution", after blackboxed scripts, special breakpoints, etc.)
- eventual pause state variables (e.g. Step over", Step out", "Step next", etc.)
Only clear eventual pause state variables if we're at the desired call frame, or if we're actually pausing at a breakpoint (because the pause reason is now the breakpoint, not the stepping action).
* LayoutTests/inspector/debugger/stepping/stepOver-breakpoint.html: Added.
* LayoutTests/inspector/debugger/stepping/stepOver-breakpoint-expected.txt: Added.
Canonical link: https://commits.webkit.org/264160@main
More information about the webkit-changes
mailing list