diff --git a/src/compiler/program.ts b/src/compiler/program.ts index c2a1e6ade66..dbcb9f7c617 100644 --- a/src/compiler/program.ts +++ b/src/compiler/program.ts @@ -1003,7 +1003,7 @@ namespace ts { } const category = DiagnosticCategory[diagnostic.category].toLowerCase(); - output += `${ category } TS${ diagnostic.code }: ${ flattenDiagnosticMessageText(diagnostic.messageText, sys.newLine) }${ sys.newLine }`; + output += `${ category } TS${ diagnostic.code }: ${ flattenDiagnosticMessageText(diagnostic.messageText, host.getNewLine()) }${ host.getNewLine() }`; } return output; }