Don't call push.apply, it can stack overflow with large arrays.

This commit is contained in:
Cyrus Najmabadi committed 2015-07-07 17:44:22 -07:00
1 parent 9b2d44a676
commit e0e9bcff46
4 files changed
+18 -18

No files matched your search

+1 -1
View File
@@ -3305,7 +3305,7 @@ namespace ts {
let declarations: Declaration[] = [];
for (let prop of props) {
if (prop.declarations) {
declarations.push.apply(declarations, prop.declarations);
addRange(declarations, prop.declarations);
}
propTypes.push(getTypeOfSymbol(prop));
}