Skip to content
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

benchmark: refactor for consistent style #25944

Closed
wants to merge 2 commits into from

Conversation

Trott
Copy link
Member

@Trott Trott commented Feb 5, 2019

Code in benchmark directory sometimes uses function () {} for anonymous
callbacks and sometimes uses () => {}. Multi-line arrays sometimes
have a trailing comma and sometimes do not. Update to always use arrow
functions for anonymous callbacks and trailing commas for multiline
arrays.

This is more churn than I was expecting, but after looking it over, it's right at the edge of my churn-tolerance, so I'm good with it. I'll be happy to do the backports to 11/10/8/6 as necessary, although probably dont-land-on labels are fine for code in the benchmark directory.
¯\(ツ)

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

@nodejs-github-bot nodejs-github-bot added benchmark Issues and PRs related to the benchmark subsystem. buffer Issues and PRs related to the buffer subsystem. child_process Issues and PRs related to the child_process subsystem. cluster Issues and PRs related to the cluster subsystem. crypto Issues and PRs related to the crypto subsystem. dgram Issues and PRs related to the dgram subsystem / UDP. events Issues and PRs related to the events subsystem / EventEmitter. v8 engine Issues and PRs related to the V8 dependency. labels Feb 5, 2019
@Trott
Copy link
Member Author

Trott commented Feb 5, 2019

Benchmark tests in CI: https://ci.nodejs.org/job/node-test-commit-custom-suites/860/

Code in benchmark directory sometimes uses `function () {}` for
anonymous callbacks and sometimes uses `() => {}`. Multi-line arrays
sometimes have a trailing comma and sometimes do not. Update to always
use arrow functions for anonymous callbacks and trailing commas for
multiline arrays.
All benchmark code uses trailing commas on multi-line arrays and arrow
functions for anonymous callbacks. Apply lint rules to that effect.
@Trott
Copy link
Member Author

Trott commented Feb 5, 2019

Benchmark tests in CI: https://ci.nodejs.org/job/node-test-commit-custom-suites/861/

@Trott
Copy link
Member Author

Trott commented Feb 5, 2019

Copy link
Contributor

@antsmartian antsmartian left a comment

Choose a reason for hiding this comment

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

Good work.. 👍

@Trott Trott added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Feb 6, 2019
@Trott
Copy link
Member Author

Trott commented Feb 7, 2019

Landed in d310d8d...2a21254

@Trott Trott closed this Feb 7, 2019
Trott added a commit to Trott/io.js that referenced this pull request Feb 7, 2019
Code in benchmark directory sometimes uses `function () {}` for
anonymous callbacks and sometimes uses `() => {}`. Multi-line arrays
sometimes have a trailing comma and sometimes do not. Update to always
use arrow functions for anonymous callbacks and trailing commas for
multiline arrays.

PR-URL: nodejs#25944
Reviewed-By: Anto Aravinth <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Trott added a commit to Trott/io.js that referenced this pull request Feb 7, 2019
All benchmark code uses trailing commas on multi-line arrays and arrow
functions for anonymous callbacks. Apply lint rules to that effect.

PR-URL: nodejs#25944
Reviewed-By: Anto Aravinth <[email protected]>
Reviewed-By: James M Snell <[email protected]>
addaleax pushed a commit that referenced this pull request Feb 7, 2019
Code in benchmark directory sometimes uses `function () {}` for
anonymous callbacks and sometimes uses `() => {}`. Multi-line arrays
sometimes have a trailing comma and sometimes do not. Update to always
use arrow functions for anonymous callbacks and trailing commas for
multiline arrays.

PR-URL: #25944
Reviewed-By: Anto Aravinth <[email protected]>
Reviewed-By: James M Snell <[email protected]>
addaleax pushed a commit that referenced this pull request Feb 7, 2019
All benchmark code uses trailing commas on multi-line arrays and arrow
functions for anonymous callbacks. Apply lint rules to that effect.

PR-URL: #25944
Reviewed-By: Anto Aravinth <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@targos targos mentioned this pull request Feb 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. benchmark Issues and PRs related to the benchmark subsystem. buffer Issues and PRs related to the buffer subsystem. child_process Issues and PRs related to the child_process subsystem. cluster Issues and PRs related to the cluster subsystem. crypto Issues and PRs related to the crypto subsystem. dgram Issues and PRs related to the dgram subsystem / UDP. events Issues and PRs related to the events subsystem / EventEmitter. v8 engine Issues and PRs related to the V8 dependency.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants