Skip to content

Commit 8b8c490

Browse files
author
Kanchalai Tanglertsampan
committed
Address code review: fix indentation
1 parent a928ad3 commit 8b8c490

17 files changed

+46
-44
lines changed

src/compiler/emitter.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1348,7 +1348,9 @@ namespace ts {
13481348
writeToken(SyntaxKind.OpenBraceToken, node.pos, /*contextNode*/ node);
13491349
emitBlockStatements(node);
13501350
// We have to call emitLeadingComments explicitly here because otherwise leading comments of the close brace token will not be emitted
1351+
increaseIndent();
13511352
emitLeadingCommentsOfPosition(node.statements.end);
1353+
decreaseIndent();
13521354
writeToken(SyntaxKind.CloseBraceToken, node.statements.end, /*contextNode*/ node);
13531355
}
13541356
}

tests/baselines/reference/amdImportAsPrimaryExpression.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,6 @@ define(["require", "exports"], function (require, exports) {
2626
define(["require", "exports", "./foo_0"], function (require, exports, foo) {
2727
"use strict";
2828
if (foo.E1.A === 0) {
29-
// Should cause runtime import - interesting optimization possibility, as gets inlined to 0.
29+
// Should cause runtime import - interesting optimization possibility, as gets inlined to 0.
3030
}
3131
});

tests/baselines/reference/argsInScope.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ var C = (function () {
1717
}
1818
C.prototype.P = function (ii, j, k) {
1919
for (var i = 0; i < arguments.length; i++) {
20-
// WScript.Echo("param: " + arguments[i]);
20+
// WScript.Echo("param: " + arguments[i]);
2121
}
2222
};
2323
return C;

tests/baselines/reference/commentLeadingCloseBrace.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ function ifelse() {
1616
if (commentedParameters(1, 2)) {
1717
/*comment1*/
1818
commentedParameters(3, 4);
19-
/*comment2*/
19+
/*comment2*/
2020
}
2121
else {
2222
commentedParameters(5, 6);

tests/baselines/reference/commonJSImportAsPrimaryExpression.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,5 +27,5 @@ exports.C1 = C1;
2727
"use strict";
2828
var foo = require("./foo_0");
2929
if (foo.C1.s1) {
30-
// Should cause runtime import
30+
// Should cause runtime import
3131
}

tests/baselines/reference/duplicateLocalVariable1.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -391,7 +391,7 @@ var TestRunner = (function () {
391391
}
392392
}
393393
if (testResult === false) {
394-
//console.log(e.message);
394+
//console.log(e.message);
395395
}
396396
}
397397
if ((testcase.errorMessageRegEx !== undefined) && !exception) {

tests/baselines/reference/jsFileCompilationLetBeingRenamed.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@ function foo(a) {
99
//// [out.js]
1010
function foo(a) {
1111
for (var a_1 = 0; a_1 < 10; a_1++) {
12-
// do something
12+
// do something
1313
}
1414
}

tests/baselines/reference/narrowExceptionVariableInCatchClause.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ function tryCatch() {
2727
//// [narrowExceptionVariableInCatchClause.js]
2828
function tryCatch() {
2929
try {
30-
// do stuff...
30+
// do stuff...
3131
}
3232
catch (err) {
3333
if (isFooError(err)) {

tests/baselines/reference/noCatchBlock.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/baselines/reference/noCatchBlock.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)