Skip to content

Conversation

@antsmartian
Copy link
Contributor

@antsmartianantsmartian commented Jul 13, 2018

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

@nodejs-github-botnodejs-github-bot added readline Issues and PRs related to the built-in readline module. zlib Issues and PRs related to the zlib subsystem. labels Jul 13, 2018
Copy link
Contributor

@apapirovskiapapirovski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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 fnWrap.

@antsmartian
Copy link
ContributorAuthor

Yeah sure. Will do the same and update.

@antsmartian
Copy link
ContributorAuthor

@apapirovski Ok, I did skimmed the source code of zlip.js, looks like we can use syncBufferWrapper, as this function just returns the zlibBufferSync and used for different compression formats like gzip, gunzip etc in sync mode. Similary, for zlibBuffer, we can name it as asyncBufferWrapper as the implementation of zlibBuffer is based on event emitters (async). Let me know if I'm wrong otherwise here.

For SIGCONT, I better rename the function to be continueProcess, as I guess that suits more natural. Thanks.

lib/readline.js Outdated
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes that make sense, may be will update the same in another PR. Thanks for your time on this.

@trivikr
Copy link
Member

Thank you @antsmartian for your first PR in Node.js core!

The user.email needs to be updated in the commit as specified in this step
The current user.email is not registered with Github

@antsmartian
Copy link
ContributorAuthor

@trivikr Thanks, for some reason, my git config wasn't correct. Now fixed.

@trivikr
Copy link
Member

@apapirovski
Copy link
Contributor

@apapirovskiapapirovski added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Jul 29, 2018
@maclover7
Copy link
Contributor

Resumed CI: https://ci.nodejs.org/job/node-test-pull-request/16082/

@maclover7
Copy link
Contributor

Resumed once again, infrastructure issue on OSX: https://ci.nodejs.org/job/node-test-pull-request/16141/

@trivikr
Copy link
Member

Landed in fc6f49a

@trivikrtrivikr closed this Aug 2, 2018
trivikr pushed a commit that referenced this pull request Aug 2, 2018
PR-URL: #21792 Reviewed-By: Anatoli Papirovski <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Yuta Hiroto <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Jon Moss <[email protected]>
targos pushed a commit that referenced this pull request Aug 2, 2018
PR-URL: #21792 Reviewed-By: Anatoli Papirovski <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Yuta Hiroto <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Jon Moss <[email protected]>
@antsmartianantsmartian deleted the anonymous_functions branch August 4, 2018 08:39
@rvaggrvagg mentioned this pull request Aug 13, 2018
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author readyPRs that have at least one approval, no pending requests for changes, and a CI started.readlineIssues and PRs related to the built-in readline module.zlibIssues and PRs related to the zlib subsystem.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants

@antsmartian@trivikr@apapirovski@maclover7@jasnell@cjihrig@hiroppy@nodejs-github-bot