angular/angular.js — pull request #8525 by caitp (2014-08-07 14:20:02+00:00)
Title: fix(forEach): match behaviour of Array.prototype.forEach (ignore missing properties)

Array.prototype.forEach will not invoke the callback function if the properety
is not present in the object. Because of this, we have the illusion of not
iterating over non-added properties in a sparse array.

From ECMAScript:

9. Repeat while k < len
a. Let Pk be ToString(k).
b. Let kPresent be HasProperty(O, Pk).
c. ReturnIfAbrupt(kPresent).
d. If kPresent is true, then
i. Let kValue be Get(O, Pk)
... (steps for invoking the function and aborting if it throws)

Closes #8510 Closes #8522