3 ms·
> if you assign to an index that's way past the end of your the elements array, V8 may downgrade the elements to dictionary mode... avoid copying from the back
by zbjornson 10y ago
> if you assign to an index that's way past the end of your the elements array, V8 may downgrade the elements to dictionary mode... avoid copying from the back
Sublime I think still has the snippet for "optimized for loop" that runs in reverse. I have never seen that improve performance, and I didn't know that it could actually be harmful if used to initialize an array.