Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
#847 was a valuable change to the code base in which we definetely cleaned things up.
In this PR I want to add a special case, where we consider the array case separate from the generic case. I think this is important as I believe the parallel cases of
each
,eachOf
,map
,filter
, etc when provided arrays are one of the hottest paths in the library. Therefore, I have decided to optimize parallel array processing for all methods which useeachOf
for the array case and defer to theeachOfLimit
implementation for objects and iterators.On my run of the relevant benchmarks, the suite ran 27.4% faster
/cc @aearly @charlierudolph