cujojs / when

A solid, fast Promises/A+ and when() implementation, plus other async goodies.
Other
3.44k stars 396 forks source link

Improve map() perf #390

Closed briancavalier closed 9 years ago

briancavalier commented 9 years ago

There was a perf regression in map() in 889d8d2b99d982c9660fab662915ca14fcb1fdfa. This change not only fixes the regression, but improves map() perf well beyond what it was previously by using the new traverse() operations, which is an abstracted version of the very fast all() algorithm. Now, both all() and map() use traverse().

See examples of the difference here: https://gist.github.com/briancavalier/c5332accfd216bde374d