Files
tsgo/testdata/baselines/reference/tsc/forceConsistentCasingInFileNames/with-relative-and-non-relative-file-resolutions.js

3.3 KiB

currentDirectory::/user/username/projects/myproject
useCaseSensitiveFileNames::false
Input::
//// [/user/username/projects/myproject/node_modules/fp-ts/lib/struct.d.ts] *new*
export function foo(): void
//// [/user/username/projects/myproject/src/struct.d.ts] *new*
import * as xs1 from "fp-ts/lib/Struct";
import * as xs2 from "fp-ts/lib/struct";
import * as xs3 from "./Struct";
import * as xs4 from "./struct";
 
tsgo /user/username/projects/myproject/src/struct.d.ts --forceConsistentCasingInFileNames --explainFiles
ExitStatus:: DiagnosticsPresent_OutputsGenerated
Output::
src/struct.d.ts:2:22 - error TS1149: File name '/user/username/projects/myproject/node_modules/fp-ts/lib/struct.d.ts' differs from already included file name '/user/username/projects/myproject/node_modules/fp-ts/lib/Struct.d.ts' only in casing.
The file is in the program because:
Imported via "fp-ts/lib/Struct" from file '/user/username/projects/myproject/src/struct.d.ts'
Imported via "fp-ts/lib/struct" from file '/user/username/projects/myproject/src/struct.d.ts'
 
2 import * as xs2 from "fp-ts/lib/struct";
~~~~~~~~~~~~~~~~~~
 
src/struct.d.ts:1:22 - File is included via import here.
1 import * as xs1 from "fp-ts/lib/Struct";
~~~~~~~~~~~~~~~~~~
 
src/struct.d.ts:3:22 - error TS1149: File name '/user/username/projects/myproject/src/Struct.d.ts' differs from already included file name '/user/username/projects/myproject/src/struct.d.ts' only in casing.
The file is in the program because:
Root file specified for compilation
Imported via "./Struct" from file '/user/username/projects/myproject/src/struct.d.ts'
Imported via "./struct" from file '/user/username/projects/myproject/src/struct.d.ts'
 
3 import * as xs3 from "./Struct";
~~~~~~~~~~
 
src/struct.d.ts:4:22 - File is included via import here.
4 import * as xs4 from "./struct";
~~~~~~~~~~
 
../../../../home/src/tslibs/TS/Lib/lib.es2025.full.d.ts
Default library for target 'ES2025'
node_modules/fp-ts/lib/Struct.d.ts
Imported via "fp-ts/lib/Struct" from file 'src/struct.d.ts'
Imported via "fp-ts/lib/struct" from file 'src/struct.d.ts'
src/struct.d.ts
Root file specified for compilation
Imported via "./Struct" from file 'src/struct.d.ts'
Imported via "./struct" from file 'src/struct.d.ts'
 
Found 2 errors in the same file, starting at: src/struct.d.ts:2
 
//// [/home/src/tslibs/TS/Lib/lib.es2025.full.d.ts] *Lib*
/// <reference no-default-lib="true"/>
interface Boolean {}
interface Function {}
interface CallableFunction {}
interface NewableFunction {}
interface IArguments {}
interface Number { toExponential: any; }
interface Object {}
interface RegExp {}
interface String { charAt: any; }
interface Array<T> { length: number; [n: number]: T; }
interface ReadonlyArray<T> {}
interface SymbolConstructor {
(desc?: string | number): symbol;
for(name: string): symbol;
readonly toStringTag: symbol;
}
declare var Symbol: SymbolConstructor;
interface Symbol {
readonly [Symbol.toStringTag]: string;
}
declare const console: { log(msg: any): void; };