diff --git a/src/compiler/tsc.ts b/src/compiler/tsc.ts index 7cf8864d357..b39c017384e 100644 --- a/src/compiler/tsc.ts +++ b/src/compiler/tsc.ts @@ -667,7 +667,7 @@ namespace ts { } function printHelp() { - const output: any = []; + const output: string[] = []; // We want to align our "syntax" and "examples" commands to a certain margin. const syntaxLength = getDiagnosticText(Diagnostics.Syntax_Colon_0, "").length; @@ -765,9 +765,10 @@ namespace ts { output.push(sys.newLine); } } - output.forEach(function (val: any) { - sys.write(val); - }); + + for (const line of output) { + sys.write(line); + } return; function getParamType(option: CommandLineOption) {