-
-
Notifications
You must be signed in to change notification settings - Fork 31.6k
fs: remove needless assignment of null #10260
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
Looks good but could you edit the commit message & PR title so that it starts with |
This line `pool = null;` isn't needed and has been around since the first iteration of streams. I can't find a good reason for it to exist, it's not more readable, nor does it seem to trick the compiler into any optimizations.
53d62e9
to
4280d8e
Compare
/cc @nodejs/streams |
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.
LGTM
(contrary to popular belief, this is not a streams change :P)
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.
LGTM even it it is not a stream change :D.
Is there a @nodejs/fs group to cc? |
cc/ @nodejs/fs |
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.
Seems straightforward. The first thing allocNewPool()
does is assign pool
a new value.
Landed 1081f0f |
This line `pool = null;` isn't needed and has been around since the first iteration of streams. I can't find a good reason for it to exist, it's not more readable, nor does it seem to trick the compiler into any optimizations. PR-URL: nodejs#10260 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This line `pool = null;` isn't needed and has been around since the first iteration of streams. I can't find a good reason for it to exist, it's not more readable, nor does it seem to trick the compiler into any optimizations. PR-URL: #10260 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This line `pool = null;` isn't needed and has been around since the first iteration of streams. I can't find a good reason for it to exist, it's not more readable, nor does it seem to trick the compiler into any optimizations. PR-URL: #10260 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This line `pool = null;` isn't needed and has been around since the first iteration of streams. I can't find a good reason for it to exist, it's not more readable, nor does it seem to trick the compiler into any optimizations. PR-URL: #10260 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This line `pool = null;` isn't needed and has been around since the first iteration of streams. I can't find a good reason for it to exist, it's not more readable, nor does it seem to trick the compiler into any optimizations. PR-URL: #10260 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
Checklist
make -j4 test
(UNIX), orvcbuild test nosign
(Windows) passesAffected core subsystem(s)
streams
Description of change
This line
pool = null;
isn't needed and has been around since the first iteration offs.stream
. I can't find a good reason for it to exist, it's not more readable, nor does it seem to trick the compiler into any optimizations.