Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upnamed anonymous functions in readline & zlib.js #21792
Conversation
nodejs-github-bot
added
readline
zlib
labels
Jul 13, 2018
apapirovski
reviewed
Jul 13, 2018
|
Hi @antsmartian, the goal of naming these functions should be to make a more useful name than the anonymous one. Please try to consider the use cases for these functions and name based on that. In particular this applies to |
This comment has been minimized.
This comment has been minimized.
|
Yeah sure. Will do the same and update. |
This comment has been minimized.
This comment has been minimized.
|
@apapirovski Ok, I did skimmed the source code of For |
antsmartian
force-pushed the
antsmartian:anonymous_functions
branch
from
31d0635
to
6e0e792
Jul 14, 2018
apapirovski
approved these changes
Jul 15, 2018
| @@ -843,7 +843,7 @@ Interface.prototype._ttyWrite = function(s, key) { | |||
| if (this.listenerCount('SIGTSTP') > 0) { | |||
| this.emit('SIGTSTP'); | |||
| } else { | |||
| process.once('SIGCONT', (function(self) { | |||
| process.once('SIGCONT', (function continueProcess(self) { | |||
This comment has been minimized.
This comment has been minimized.
apapirovski
Jul 15, 2018
Member
So we could actually do a slightly better thing here. Instead of the IIFE, we could use an arrow function and replace self with this — unless I'm missing something. Then we will just have a normal event callback instead of this weird thing it is right now. Feel free to either do that change here or in a separate PR.
This comment has been minimized.
This comment has been minimized.
antsmartian
Jul 16, 2018
Author
Contributor
Yes that make sense, may be will update the same in another PR. Thanks for your time on this.
This comment has been minimized.
This comment has been minimized.
|
Thank you @antsmartian for your first PR in Node.js core! The |
antsmartian
force-pushed the
antsmartian:anonymous_functions
branch
from
6e0e792
to
d8ec3d9
Jul 16, 2018
This comment has been minimized.
This comment has been minimized.
|
@trivikr Thanks, for some reason, my git config wasn't correct. Now fixed. |
trivikr
approved these changes
Jul 17, 2018
cjihrig
approved these changes
Jul 17, 2018
hiroppy
approved these changes
Jul 17, 2018
jasnell
approved these changes
Jul 17, 2018
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
apapirovski
added
the
author ready
label
Jul 29, 2018
maclover7
approved these changes
Jul 30, 2018
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
Resumed once again, infrastructure issue on OSX: https://ci.nodejs.org/job/node-test-pull-request/16141/ |
This comment has been minimized.
This comment has been minimized.
|
Landed in fc6f49a |
antsmartian commentedJul 13, 2018
•
edited
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passes