-
Notifications
You must be signed in to change notification settings - Fork 29.6k
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
inspector,vm: remove --eval wrapper #25832
Conversation
Report the actual source code when running with `--eval` and `--inspect-brk`, by telling the vm module to break on the first line of the script being executed rather than wrapping the source code in a function.
filename: ${JSON.stringify(name)}, | ||
displayErrors: true, | ||
[kVmBreakFirstLineSymbol]: ${!!breakFirstLine} | ||
});\n`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@addaleax The kVmBreakFirstLineSymbol
looks pretty handy. Is there a reason to keep it hidden and not exposed as a user facing option like a boolean breakFirstLineSymbol
options property?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jdalton Err, it’s less work for this PR? 😄 I’m not sure, but I guess it also only works while the inspector is enabled, similar to debugger;
statements?
Somebody from @nodejs/v8-inspector might know more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Supersedes #24946 (which uses debugger;
), this just removes the wrapper entirely so the source panel is cleaner in the inspector UI.
@joyeecheung Sorry, I wasn’t aware of that PR – it looks like that mostly consists of test changes that we could still apply, right? |
Landed in cca897e |
Report the actual source code when running with `--eval` and `--inspect-brk`, by telling the vm module to break on the first line of the script being executed rather than wrapping the source code in a function. PR-URL: #25832 Reviewed-By: Eugene Ostroukhov <eostroukhov@google.com> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Report the actual source code when running with `--eval` and `--inspect-brk`, by telling the vm module to break on the first line of the script being executed rather than wrapping the source code in a function. PR-URL: #25832 Reviewed-By: Eugene Ostroukhov <eostroukhov@google.com> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Report the actual source code when running with
--eval
and--inspect-brk
, by telling the vm module to break on thefirst line of the script being executed rather than wrapping
the source code in a function.
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes