4739535d71
This aligns the breakpoint behavior of YieldExpression and AwaitExpression with the behavior of AssignmentExpression in V8. It basically boils down to not reporting expression positions on SuspendGenerator bytecodes as breakable locations. In particular the initial implicit yield of any generator function is no longer a breakable position. In light of this changes we also refine https://crrev.com/c/2949099 to not be able to step to the initial implicit yield either, which would otherwise be really odd. Before: https://imgur.com/KYy9F1S.png After: https://imgur.com/gCnWU8J.png Doc: https://goo.gle/devtools-reliable-await-breakpoints Bug: chromium:901814, chromium:1319019, chromium:1246869 Fixed: chromium:1319019, chromium:1357501 Change-Id: I0c5f83e279918eb392d8f77a8a04c4c0285f938e Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3909688 Commit-Queue: Leszek Swirski <leszeks@chromium.org> Reviewed-by: Kim-Anh Tran <kimanh@chromium.org> Auto-Submit: Benedikt Meurer <bmeurer@chromium.org> Reviewed-by: Leszek Swirski <leszeks@chromium.org> Cr-Commit-Position: refs/heads/main@{#83392}
27 lines
1.0 KiB
Plaintext
27 lines
1.0 KiB
Plaintext
Line breakpoints for yield
|
|
|
|
Running test: testYieldInGeneratorWithLeadingWhitespace
|
|
Setting breakpoint on `yield this.foo()` in `obj.barGenerator`
|
|
Calling `obj.barGenerator().next()`
|
|
Hit breakpoint before calling into `this.foo`
|
|
|
|
Running test: testYieldInGeneratorWithoutLeadingWhitespace
|
|
Setting breakpoint on `await this.foo()` in `obj.bazGenerator`
|
|
Calling `obj.bazGenerator().next()`
|
|
Hit breakpoint before calling into `this.foo`
|
|
|
|
Running test: testYieldInAsyncGeneratorWithLeadingWhitespace
|
|
Setting breakpoint on `yield this.foo()` in `obj.barAsyncGenerator`
|
|
Calling `obj.barAsyncGenerator().next()`
|
|
Hit breakpoint before calling into `this.foo`
|
|
|
|
Running test: testYieldInAsyncGeneratorWithoutLeadingWhitespace
|
|
Setting breakpoint on `yield this.foo()` in `obj.bazAsyncGenerator`
|
|
Calling `obj.bazAsyncGenerator().next()`
|
|
Hit breakpoint before calling into `this.foo`
|
|
|
|
Running test: testYieldInMinifiedGenerator
|
|
Setting breakpoint on `yield this.foo()` in `obj.minifiedGenerator`
|
|
Calling `obj.minifiedGenerator().next()`
|
|
Hit breakpoint before calling into `this.foo`
|