Properly adjust nodes while walking down the tree.

This commit is contained in:
Cyrus Najmabadi
2014-12-12 02:34:53 -08:00
parent 2f833d5f97
commit 9c0e4211bc
2 changed files with 5 additions and 3 deletions

View File

@@ -801,7 +801,7 @@ module ts {
// Adjust the pos or end (or both) of the intersecting array accordingly.
adjustIntersectingElement(array, changeStart, changeRangeOldEnd, changeRangeNewEnd, delta);
for (var i = 0, n = array.length; i < n; i++) {
forEachChild(array[i], visitNode, visitArray);
visitNode(array[i]);
}
}
// else {
@@ -908,7 +908,7 @@ module ts {
array.end += delta;
for (var i = 0, n = array.length; i < n; i++) {
forEachChild(array[i], visitNode, visitArray);
visitNode(array[i]);
}
}
}