do not indent tokens with errors

This commit is contained in:
Vladimir Matveev
2014-11-05 15:29:51 -08:00
parent f28c1a3498
commit 9a30fa882b
+1 -1
View File
@@ -646,7 +646,7 @@ module ts.formatting {
}
}
}
if (isTokenInRange) {
if (isTokenInRange && !rangeContainsError(currentTokenInfo.token)) {
insertIndentation(currentTokenInfo.token.pos, indentation.getEffectiveIndentation(tokenStart.line, currentTokenInfo.token.kind), lineAdded);
}
}