-
Notifications
You must be signed in to change notification settings - Fork 22
Scopes: Algorithm for computing original stack frames #219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
* Combine 'IsStackFrame' and 'IsHidden' of generated range into a single enum field. * Get rid of Sub-Range Binding Record in favor of a list of list of binding records.
Co-authored-by: Justin Ridgewell <[email protected]>
* Include 'scopes' in the overall source map example
* Clarify pre-order for scope/range start/end items
* Clarify ~none~ for StackFrametype
* Introduce 'BindingExpression' as a dedicated name for sub-range
binding VLQs
* Don't reserve 'A' for as an item tag
705d528 to
bf3765c
Compare
|
Thanks for writing up the algorithm! I had a cursory initial look. IMHO Rather then having one catch all abstract operation I suggest we spec out some basic building blocks. Concretely I suggest the following 3 "entry point operations":
|
|
Thanks for the feedback!
|
Good point, my implementation and this PR currently work with only one generated source. |
|
I think this can be emulated using Runtime.callFunctionOn. |
Nice!
OK, we could use "evaluate in this scope" in the algorithm and then append a description how "evaluate in this scope" can be emulated using "evaluate with bindings". |
I'm not sure how'd you create the bindings object in the first place. You'd still need to read the values for generated variables off the stack or out of closure contexts. Debugger.evaluateOnCallFrame has this built-in by basically building At least from a V8 and Chrome DevTools perspective it would be much easier to just extend |
c2668b2 to
60e0844
Compare
60e0844 to
22dd1da
Compare
|
I have added the suggested |
Preview
This is an initial draft of the algorithm for computing original stack frames (implemented here).
This PR is on top of #196 and it also makes use of
GetOriginalPositionfrom #195.TODO: