Use / in paths in the auto-generated files' header (#24883)

This commit is contained in:
Nathan Shively-Sanders
2018-06-12 09:04:29 -07:00
committed by GitHub
parent d0391d2e3c
commit 51fb07523a

View File

@@ -60,7 +60,7 @@ function checkForUniqueCodes(diagnosticTable: InputDiagnosticMessageTable) {
function buildInfoFileOutput(messageTable: InputDiagnosticMessageTable, inputFilePathRel: string, thisFilePathRel: string): string {
let result =
"// <auto-generated />\r\n" +
"// generated from '" + inputFilePathRel + "' by '" + thisFilePathRel + "'\r\n" +
"// generated from '" + inputFilePathRel + "' by '" + thisFilePathRel.replace(/\\/g, '/') + "'\r\n" +
"/* @internal */\r\n" +
"namespace ts {\r\n" +
" function diag(code: number, category: DiagnosticCategory, key: string, message: string, reportsUnnecessary?: {}): DiagnosticMessage {\r\n" +
@@ -119,4 +119,4 @@ function convertPropertyName(origName: string): string {
return result;
}
main();
main();