-
Notifications
You must be signed in to change notification settings - Fork 29.8k
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
lib: Replace String concatenation with template #16922
Conversation
lib/internal/v8_prof_polyfill.js
Outdated
@@ -79,7 +79,7 @@ var line = ''; | |||
|
|||
function peekline() { | |||
const s = readline(); | |||
line = s + '\n' + line; | |||
line = `s \n` + line; |
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.
change s
as ${s}
as we need to append the const variable s instead of the letter s.
1bd5aa8
to
cb2cc74
Compare
lib/internal/v8_prof_polyfill.js
Outdated
@@ -79,7 +79,7 @@ var line = ''; | |||
|
|||
function peekline() { | |||
const s = readline(); | |||
line = s + '\n' + line; | |||
line = `${s} \n` + line; |
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.
this can cover the entire line... e.g.
line = `${s} \n${line}`;
cb2cc74
to
e4e66f3
Compare
@jasnell Thanks for your review.I have addressed your comments |
PR-URL: #16922 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Tobias Nießen <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]> Reviewed-By: Franziska Hinkelmann <[email protected]>
PR-URL: #16922 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Tobias Nießen <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]> Reviewed-By: Franziska Hinkelmann <[email protected]>
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passesAffected core subsystem(s)