Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 2 additions & 2 deletions src/compiler/commandLineParser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1278,7 +1278,7 @@ const commandOptionsWithoutBuild: CommandLineOption[] = [
paramType: Diagnostics.NEWLINE,
category: Diagnostics.Emit,
description: Diagnostics.Set_the_newline_character_for_emitting_files,
defaultValueDescription: Diagnostics.Platform_specific
defaultValueDescription: "lf"
},
{
name: "noErrorTruncation",
Expand Down Expand Up @@ -1454,7 +1454,7 @@ const commandOptionsWithoutBuild: CommandLineOption[] = [
affectsModuleResolution: true,
category: Diagnostics.Interop_Constraints,
description: Diagnostics.Ensure_that_casing_is_correct_in_imports,
defaultValueDescription: false,
defaultValueDescription: true,
},
{
name: "maxNodeModuleJsDepth",
Expand Down
2 changes: 1 addition & 1 deletion src/compiler/emitter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -741,7 +741,7 @@ export function emitFiles(resolver: EmitResolver, host: EmitHost, targetSourceFi
const sourceMapDataList: SourceMapEmitResult[] | undefined = (compilerOptions.sourceMap || compilerOptions.inlineSourceMap || getAreDeclarationMapsEnabled(compilerOptions)) ? [] : undefined;
const emittedFilesList: string[] | undefined = compilerOptions.listEmittedFiles ? [] : undefined;
const emitterDiagnostics = createDiagnosticCollection();
const newLine = getNewLineCharacter(compilerOptions, () => host.getNewLine());
const newLine = getNewLineCharacter(compilerOptions);
const writer = createTextWriter(newLine);
const { enter, exit } = performance.createTimer("printTime", "beforePrint", "afterPrint");
let bundleBuildInfo: BundleBuildInfo | undefined;
Expand Down
2 changes: 1 addition & 1 deletion src/compiler/program.ts
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,7 @@ export function createCompilerHostWorker(options: CompilerOptions, setParentNode
return getDirectoryPath(normalizePath(system.getExecutingFilePath()));
}

const newLine = getNewLineCharacter(options, () => system.newLine);
const newLine = getNewLineCharacter(options);
Copy link
Member

@sheetalkamat sheetalkamat Jan 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you also need it in createCompilerHostFromProgramHost
Also if this doesnt have matching changes in services.ts, we might have issues with compileOnSave?

const realpath = system.realpath && ((path: string) => system.realpath!(path));
const compilerHost: CompilerHost = {
getSourceFile: createGetSourceFile(fileName => compilerHost.readFile(fileName), () => options, setParentNodes),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,25 +133,25 @@ FsWatchesRecursive::
exitCode:: ExitStatus.Success

//// [/user/username/projects/myproject/packages/pkg2/build/const.js]
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });


//// [/user/username/projects/myproject/packages/pkg2/build/const.d.ts]
export type TheNum = 42;
export type TheNum = 42;


//// [/user/username/projects/myproject/packages/pkg2/build/index.js]
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });


//// [/user/username/projects/myproject/packages/pkg2/build/index.d.ts]
export type { TheNum } from 'const';
export type { TheNum } from 'const';


//// [/user/username/projects/myproject/packages/pkg2/build/tsconfig.tsbuildinfo]
{"program":{"fileNames":["../../../../../../../a/lib/lib.d.ts","../const.ts","../index.ts"],"fileInfos":[{"version":"-7698705165-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }","affectsGlobalScope":true},{"version":"-11202312776-export type TheNum = 42;","signature":"-13194036030-export type TheNum = 42;\n"},{"version":"-10837689162-export type { TheNum } from 'const';","signature":"-9751391360-export type { TheNum } from 'const';\n"}],"options":{"composite":true,"outDir":"./"},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3],"latestChangedDtsFile":"./index.d.ts"},"version":"FakeTSVersion"}
{"program":{"fileNames":["../../../../../../../a/lib/lib.d.ts","../const.ts","../index.ts"],"fileInfos":[{"version":"-7698705165-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }","affectsGlobalScope":true},{"version":"-11202312776-export type TheNum = 42;","signature":"-14496393873-export type TheNum = 42;\r\n"},{"version":"-10837689162-export type { TheNum } from 'const';","signature":"-8263302163-export type { TheNum } from 'const';\r\n"}],"options":{"composite":true,"outDir":"./"},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3],"latestChangedDtsFile":"./index.d.ts"},"version":"FakeTSVersion"}

//// [/user/username/projects/myproject/packages/pkg2/build/tsconfig.tsbuildinfo.readable.baseline.txt]
{
Expand Down Expand Up @@ -179,18 +179,18 @@ export type { TheNum } from 'const';
"../const.ts": {
"original": {
"version": "-11202312776-export type TheNum = 42;",
"signature": "-13194036030-export type TheNum = 42;\n"
"signature": "-14496393873-export type TheNum = 42;\r\n"
},
"version": "-11202312776-export type TheNum = 42;",
"signature": "-13194036030-export type TheNum = 42;\n"
"signature": "-14496393873-export type TheNum = 42;\r\n"
},
"../index.ts": {
"original": {
"version": "-10837689162-export type { TheNum } from 'const';",
"signature": "-9751391360-export type { TheNum } from 'const';\n"
"signature": "-8263302163-export type { TheNum } from 'const';\r\n"
},
"version": "-10837689162-export type { TheNum } from 'const';",
"signature": "-9751391360-export type { TheNum } from 'const';\n"
"signature": "-8263302163-export type { TheNum } from 'const';\r\n"
}
},
"options": {
Expand All @@ -215,13 +215,13 @@ export type { TheNum } from 'const';
"latestChangedDtsFile": "./index.d.ts"
},
"version": "FakeTSVersion",
"size": 958
"size": 962
}

//// [/user/username/projects/myproject/packages/pkg1/build/index.js]
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.theNum = void 0;
exports.theNum = 42;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.theNum = void 0;
exports.theNum = 42;


Original file line number Diff line number Diff line change
Expand Up @@ -134,25 +134,25 @@ FsWatchesRecursive::
exitCode:: ExitStatus.Success

//// [/user/username/projects/myproject/packages/pkg2/build/const.js]
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });


//// [/user/username/projects/myproject/packages/pkg2/build/const.d.ts]
export type TheNum = 42;
export type TheNum = 42;


//// [/user/username/projects/myproject/packages/pkg2/build/index.js]
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });


//// [/user/username/projects/myproject/packages/pkg2/build/index.d.ts]
export type { TheNum } from 'const';
export type { TheNum } from 'const';


//// [/user/username/projects/myproject/packages/pkg2/build/tsconfig.tsbuildinfo]
{"program":{"fileNames":["../../../../../../../a/lib/lib.d.ts","../const.ts","../index.ts"],"fileInfos":[{"version":"-7698705165-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }","affectsGlobalScope":true},{"version":"-11202312776-export type TheNum = 42;","signature":"-13194036030-export type TheNum = 42;\n"},{"version":"-10837689162-export type { TheNum } from 'const';","signature":"-9751391360-export type { TheNum } from 'const';\n"}],"options":{"composite":true,"outDir":"./"},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3],"latestChangedDtsFile":"./index.d.ts"},"version":"FakeTSVersion"}
{"program":{"fileNames":["../../../../../../../a/lib/lib.d.ts","../const.ts","../index.ts"],"fileInfos":[{"version":"-7698705165-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }","affectsGlobalScope":true},{"version":"-11202312776-export type TheNum = 42;","signature":"-14496393873-export type TheNum = 42;\r\n"},{"version":"-10837689162-export type { TheNum } from 'const';","signature":"-8263302163-export type { TheNum } from 'const';\r\n"}],"options":{"composite":true,"outDir":"./"},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3],"latestChangedDtsFile":"./index.d.ts"},"version":"FakeTSVersion"}

//// [/user/username/projects/myproject/packages/pkg2/build/tsconfig.tsbuildinfo.readable.baseline.txt]
{
Expand Down Expand Up @@ -180,18 +180,18 @@ export type { TheNum } from 'const';
"../const.ts": {
"original": {
"version": "-11202312776-export type TheNum = 42;",
"signature": "-13194036030-export type TheNum = 42;\n"
"signature": "-14496393873-export type TheNum = 42;\r\n"
},
"version": "-11202312776-export type TheNum = 42;",
"signature": "-13194036030-export type TheNum = 42;\n"
"signature": "-14496393873-export type TheNum = 42;\r\n"
},
"../index.ts": {
"original": {
"version": "-10837689162-export type { TheNum } from 'const';",
"signature": "-9751391360-export type { TheNum } from 'const';\n"
"signature": "-8263302163-export type { TheNum } from 'const';\r\n"
},
"version": "-10837689162-export type { TheNum } from 'const';",
"signature": "-9751391360-export type { TheNum } from 'const';\n"
"signature": "-8263302163-export type { TheNum } from 'const';\r\n"
}
},
"options": {
Expand All @@ -216,13 +216,13 @@ export type { TheNum } from 'const';
"latestChangedDtsFile": "./index.d.ts"
},
"version": "FakeTSVersion",
"size": 958
"size": 962
}

//// [/user/username/projects/myproject/packages/pkg1/build/index.js]
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.theNum = void 0;
exports.theNum = 42;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.theNum = void 0;
exports.theNum = 42;


Loading