-
Notifications
You must be signed in to change notification settings - Fork 12.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Collect _all_ symlinks a file may have witnessed when attempting to g…
…enerate specifiers (#31571)
- Loading branch information
Showing
9 changed files
with
284 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
45 changes: 45 additions & 0 deletions
45
tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
//// [tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink.ts] //// | ||
|
||
//// [impl.d.ts] | ||
export function getA(): A; | ||
export enum A { | ||
Val | ||
} | ||
//// [index.d.ts] | ||
export * from "./src/impl"; | ||
//// [package.json] | ||
{ | ||
"name": "typescript-fsa", | ||
"version": "1.0.0" | ||
} | ||
//// [impl.d.ts] | ||
export function getA(): A; | ||
export enum A { | ||
Val | ||
} | ||
//// [index.d.ts] | ||
export * from "./src/impl"; | ||
//// [package.json] | ||
{ | ||
"name": "typescript-fsa", | ||
"version": "1.0.0" | ||
} | ||
//// [index.ts] | ||
import * as _whatever from "p2"; | ||
import { getA } from "typescript-fsa"; | ||
|
||
export const a = getA(); | ||
//// [index.d.ts] | ||
export const a: import("typescript-fsa").A; | ||
|
||
|
||
|
||
//// [index.js] | ||
"use strict"; | ||
exports.__esModule = true; | ||
var typescript_fsa_1 = require("typescript-fsa"); | ||
exports.a = typescript_fsa_1.getA(); | ||
|
||
|
||
//// [index.d.ts] | ||
export declare const a: import("typescript-fsa").A; |
43 changes: 43 additions & 0 deletions
43
tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.symbols
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
=== /p1/node_modules/typescript-fsa/src/impl.d.ts === | ||
export function getA(): A; | ||
>getA : Symbol(getA, Decl(impl.d.ts, 0, 0)) | ||
>A : Symbol(A, Decl(impl.d.ts, 0, 26)) | ||
|
||
export enum A { | ||
>A : Symbol(A, Decl(impl.d.ts, 0, 26)) | ||
|
||
Val | ||
>Val : Symbol(A.Val, Decl(impl.d.ts, 1, 15)) | ||
} | ||
=== /p1/node_modules/typescript-fsa/index.d.ts === | ||
export * from "./src/impl"; | ||
No type information for this code.=== /p2/node_modules/typescript-fsa/src/impl.d.ts === | ||
export function getA(): A; | ||
>getA : Symbol(getA, Decl(impl.d.ts, 0, 0)) | ||
>A : Symbol(A, Decl(impl.d.ts, 0, 26)) | ||
|
||
export enum A { | ||
>A : Symbol(A, Decl(impl.d.ts, 0, 26)) | ||
|
||
Val | ||
>Val : Symbol(A.Val, Decl(impl.d.ts, 1, 15)) | ||
} | ||
=== /p2/node_modules/typescript-fsa/index.d.ts === | ||
export * from "./src/impl"; | ||
No type information for this code.=== /p1/index.ts === | ||
import * as _whatever from "p2"; | ||
>_whatever : Symbol(_whatever, Decl(index.ts, 0, 6)) | ||
|
||
import { getA } from "typescript-fsa"; | ||
>getA : Symbol(getA, Decl(index.ts, 1, 8)) | ||
|
||
export const a = getA(); | ||
>a : Symbol(a, Decl(index.ts, 3, 12)) | ||
>getA : Symbol(getA, Decl(index.ts, 1, 8)) | ||
|
||
=== /p2/index.d.ts === | ||
export const a: import("typescript-fsa").A; | ||
>a : Symbol(a, Decl(index.d.ts, 0, 12)) | ||
>A : Symbol(A, Decl(impl.d.ts, 0, 26)) | ||
|
||
|
41 changes: 41 additions & 0 deletions
41
tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink.types
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
=== /p1/node_modules/typescript-fsa/src/impl.d.ts === | ||
export function getA(): A; | ||
>getA : () => A | ||
|
||
export enum A { | ||
>A : A | ||
|
||
Val | ||
>Val : A | ||
} | ||
=== /p1/node_modules/typescript-fsa/index.d.ts === | ||
export * from "./src/impl"; | ||
No type information for this code.=== /p2/node_modules/typescript-fsa/src/impl.d.ts === | ||
export function getA(): A; | ||
>getA : () => A | ||
|
||
export enum A { | ||
>A : A | ||
|
||
Val | ||
>Val : A | ||
} | ||
=== /p2/node_modules/typescript-fsa/index.d.ts === | ||
export * from "./src/impl"; | ||
No type information for this code.=== /p1/index.ts === | ||
import * as _whatever from "p2"; | ||
>_whatever : typeof _whatever | ||
|
||
import { getA } from "typescript-fsa"; | ||
>getA : () => import("/p1/node_modules/typescript-fsa/index").A | ||
|
||
export const a = getA(); | ||
>a : import("/p1/node_modules/typescript-fsa/index").A | ||
>getA() : import("/p1/node_modules/typescript-fsa/index").A | ||
>getA : () => import("/p1/node_modules/typescript-fsa/index").A | ||
|
||
=== /p2/index.d.ts === | ||
export const a: import("typescript-fsa").A; | ||
>a : import("/p2/node_modules/typescript-fsa/index").A | ||
|
||
|
33 changes: 33 additions & 0 deletions
33
tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
//// [tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink2.ts] //// | ||
|
||
//// [impl.d.ts] | ||
export function getA(): A; | ||
export enum A { | ||
Val | ||
} | ||
//// [index.d.ts] | ||
export * from "./src/impl"; | ||
//// [package.json] | ||
{ | ||
"name": "typescript-fsa", | ||
"version": "1.0.0" | ||
} | ||
//// [index.ts] | ||
import * as _whatever from "p2"; | ||
import { getA } from "typescript-fsa"; | ||
|
||
export const a = getA(); | ||
//// [index.d.ts] | ||
export const a: import("typescript-fsa").A; | ||
|
||
|
||
|
||
//// [index.js] | ||
"use strict"; | ||
exports.__esModule = true; | ||
var typescript_fsa_1 = require("typescript-fsa"); | ||
exports.a = typescript_fsa_1.getA(); | ||
|
||
|
||
//// [index.d.ts] | ||
export declare const a: import("typescript-fsa").A; |
30 changes: 30 additions & 0 deletions
30
tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.symbols
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
=== /cache/typescript-fsa/src/impl.d.ts === | ||
export function getA(): A; | ||
>getA : Symbol(getA, Decl(impl.d.ts, 0, 0)) | ||
>A : Symbol(A, Decl(impl.d.ts, 0, 26)) | ||
|
||
export enum A { | ||
>A : Symbol(A, Decl(impl.d.ts, 0, 26)) | ||
|
||
Val | ||
>Val : Symbol(A.Val, Decl(impl.d.ts, 1, 15)) | ||
} | ||
=== /cache/typescript-fsa/index.d.ts === | ||
export * from "./src/impl"; | ||
No type information for this code.=== /p1/index.ts === | ||
import * as _whatever from "p2"; | ||
>_whatever : Symbol(_whatever, Decl(index.ts, 0, 6)) | ||
|
||
import { getA } from "typescript-fsa"; | ||
>getA : Symbol(getA, Decl(index.ts, 1, 8)) | ||
|
||
export const a = getA(); | ||
>a : Symbol(a, Decl(index.ts, 3, 12)) | ||
>getA : Symbol(getA, Decl(index.ts, 1, 8)) | ||
|
||
=== /p2/index.d.ts === | ||
export const a: import("typescript-fsa").A; | ||
>a : Symbol(a, Decl(index.d.ts, 0, 12)) | ||
>A : Symbol(A, Decl(impl.d.ts, 0, 26)) | ||
|
||
|
29 changes: 29 additions & 0 deletions
29
tests/baselines/reference/declarationEmitForGlobalishSpecifierSymlink2.types
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
=== /cache/typescript-fsa/src/impl.d.ts === | ||
export function getA(): A; | ||
>getA : () => A | ||
|
||
export enum A { | ||
>A : A | ||
|
||
Val | ||
>Val : A | ||
} | ||
=== /cache/typescript-fsa/index.d.ts === | ||
export * from "./src/impl"; | ||
No type information for this code.=== /p1/index.ts === | ||
import * as _whatever from "p2"; | ||
>_whatever : typeof _whatever | ||
|
||
import { getA } from "typescript-fsa"; | ||
>getA : () => import("/cache/typescript-fsa/index").A | ||
|
||
export const a = getA(); | ||
>a : import("/cache/typescript-fsa/index").A | ||
>getA() : import("/cache/typescript-fsa/index").A | ||
>getA : () => import("/cache/typescript-fsa/index").A | ||
|
||
=== /p2/index.d.ts === | ||
export const a: import("typescript-fsa").A; | ||
>a : import("/cache/typescript-fsa/index").A | ||
|
||
|
35 changes: 35 additions & 0 deletions
35
tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
// @useCaseSensitiveFilenames: true | ||
// @declaration: true | ||
// @filename: /p1/node_modules/typescript-fsa/src/impl.d.ts | ||
export function getA(): A; | ||
export enum A { | ||
Val | ||
} | ||
// @filename: /p1/node_modules/typescript-fsa/index.d.ts | ||
export * from "./src/impl"; | ||
// @filename: /p1/node_modules/typescript-fsa/package.json | ||
{ | ||
"name": "typescript-fsa", | ||
"version": "1.0.0" | ||
} | ||
// @filename: /p2/node_modules/typescript-fsa/src/impl.d.ts | ||
export function getA(): A; | ||
export enum A { | ||
Val | ||
} | ||
// @filename: /p2/node_modules/typescript-fsa/index.d.ts | ||
export * from "./src/impl"; | ||
// @filename: /p2/node_modules/typescript-fsa/package.json | ||
{ | ||
"name": "typescript-fsa", | ||
"version": "1.0.0" | ||
} | ||
// @filename: /p1/index.ts | ||
import * as _whatever from "p2"; | ||
import { getA } from "typescript-fsa"; | ||
|
||
export const a = getA(); | ||
// @filename: /p2/index.d.ts | ||
export const a: import("typescript-fsa").A; | ||
|
||
// @link: /p2 -> /p1/node_modules/p2 |
25 changes: 25 additions & 0 deletions
25
tests/cases/compiler/declarationEmitForGlobalishSpecifierSymlink2.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// @useCaseSensitiveFilenames: true | ||
// @declaration: true | ||
// @filename: /cache/typescript-fsa/src/impl.d.ts | ||
export function getA(): A; | ||
export enum A { | ||
Val | ||
} | ||
// @filename: /cache/typescript-fsa/index.d.ts | ||
export * from "./src/impl"; | ||
// @filename: /cache/typescript-fsa/package.json | ||
{ | ||
"name": "typescript-fsa", | ||
"version": "1.0.0" | ||
} | ||
// @filename: /p1/index.ts | ||
import * as _whatever from "p2"; | ||
import { getA } from "typescript-fsa"; | ||
|
||
export const a = getA(); | ||
// @filename: /p2/index.d.ts | ||
export const a: import("typescript-fsa").A; | ||
|
||
// @link: /p2 -> /p1/node_modules/p2 | ||
// @link: /cache/typescript-fsa -> /p1/node_modules/typescript-fsa | ||
// @link: /cache/typescript-fsa -> /p2/node_modules/typescript-fsa |