| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Look at the status of the `MessagePort` rather than relying on a timeout.
|
@addaleax build started: https://ci.nodejs.org/blue/organizations/jenkins/node-test-pull-request-lite-pipeline/detail/node-test-pull-request-lite-pipeline/772/pipeline |
Sorry, something went wrong.
|
@nodejs/workers |
Sorry, something went wrong.
There was a problem hiding this comment.
Nice!
Sorry, something went wrong.
|
Fixed linter nits. |
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM with a few nits.
Sorry, something went wrong.
|
|
||
| function tick(n, cb) { | ||
| if (--n > 0) | ||
| return setImmediate(() => tick(n - 1, cb)); |
There was a problem hiding this comment.
Is return needed here?
Sorry, something went wrong.
There was a problem hiding this comment.
No, removed it :)
Sorry, something went wrong.
| port1.postMessage(2); | ||
|
|
||
| function tick(n, cb) { | ||
| if (--n > 0) |
There was a problem hiding this comment.
This actually makes half-the-n ticks, was this intentional?
Sorry, something went wrong.
There was a problem hiding this comment.
Nope. Thanks for catching!
Sorry, something went wrong.
| } : { | ||
| active: true, | ||
| refed: ref | ||
| }, this); |
There was a problem hiding this comment.
Nit: could you please put this on a separate line as it's kind of confusing?
Also, I'd suggest extracting second argument creation to a separate variable to make it easier to understand =). Though I'm fine with this too.
Sorry, something went wrong.
There was a problem hiding this comment.
Done (moving to a separate line)
Sorry, something went wrong.
|
Resume CI: https://ci.nodejs.org/job/node-test-pull-request/16975/ (:heavy_check_mark:) |
Sorry, something went wrong.
Sorry, something went wrong.
PR-URL: #22658 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Look at the status of the `MessagePort` rather than relying on a timeout. PR-URL: #22658 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
PR-URL: #22658 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Look at the status of the `MessagePort` rather than relying on a timeout. PR-URL: #22658 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
PR-URL: #22658 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Look at the status of the `MessagePort` rather than relying on a timeout. PR-URL: #22658 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
| Back | FazBrowse Home | New Git URL |
Checklist