mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Add path back-reference tests
This commit is contained in:
@@ -22233,7 +22233,7 @@ namespace ts {
|
||||
for (const decl of indexSymbol.declarations) {
|
||||
const declaration = <SignatureDeclaration>decl;
|
||||
if (declaration.parameters.length === 1 && declaration.parameters[0].type) {
|
||||
switch (declaration.parameters[0].type.kind) {
|
||||
switch (declaration.parameters[0].type!.kind) {
|
||||
case SyntaxKind.StringKeyword:
|
||||
if (!seenStringIndexer) {
|
||||
seenStringIndexer = true;
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.0": { "*" : ["ts3.0/*"] }
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,18 +20,18 @@ declare module "ext/other" {
|
||||
|
||||
//// [index.d.ts]
|
||||
declare module "ext" {
|
||||
export const a = "ts3.0 a";
|
||||
export const a = "ts3.1 a";
|
||||
}
|
||||
declare module "ext/other" {
|
||||
export const b = "ts3.0 b";
|
||||
export const b = "ts3.1 b";
|
||||
}
|
||||
|
||||
//// [main.ts]
|
||||
import { a } from "ext";
|
||||
import { b } from "ext/other";
|
||||
|
||||
const aa: "ts3.0 a" = a;
|
||||
const bb: "ts3.0 b" = b;
|
||||
const aa: "ts3.1 a" = a;
|
||||
const bb: "ts3.1 b" = b;
|
||||
|
||||
|
||||
//// [main.js]
|
||||
|
||||
@@ -5,25 +5,25 @@ import { a } from "ext";
|
||||
import { b } from "ext/other";
|
||||
>b : Symbol(b, Decl(main.ts, 1, 8))
|
||||
|
||||
const aa: "ts3.0 a" = a;
|
||||
const aa: "ts3.1 a" = a;
|
||||
>aa : Symbol(aa, Decl(main.ts, 3, 5))
|
||||
>a : Symbol(a, Decl(main.ts, 0, 8))
|
||||
|
||||
const bb: "ts3.0 b" = b;
|
||||
const bb: "ts3.1 b" = b;
|
||||
>bb : Symbol(bb, Decl(main.ts, 4, 5))
|
||||
>b : Symbol(b, Decl(main.ts, 1, 8))
|
||||
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts ===
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts ===
|
||||
declare module "ext" {
|
||||
>"ext" : Symbol("ext", Decl(index.d.ts, 0, 0))
|
||||
|
||||
export const a = "ts3.0 a";
|
||||
export const a = "ts3.1 a";
|
||||
>a : Symbol(a, Decl(index.d.ts, 1, 16))
|
||||
}
|
||||
declare module "ext/other" {
|
||||
>"ext/other" : Symbol("ext/other", Decl(index.d.ts, 2, 1))
|
||||
|
||||
export const b = "ts3.0 b";
|
||||
export const b = "ts3.1 b";
|
||||
>b : Symbol(b, Decl(index.d.ts, 4, 16))
|
||||
}
|
||||
|
||||
|
||||
@@ -11,27 +11,27 @@
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext.d.ts' does not exist.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/moduleResolution/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"Module name 'index', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/index'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts'. ========",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'. ========",
|
||||
"======== Resolving module 'ext/other' from 'tests/cases/conformance/moduleResolution/main.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"Module name 'other', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/other'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.d.ts' does not exist.",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts' does not exist.",
|
||||
"Directory 'tests/cases/conformance/moduleResolution/node_modules/@types' does not exist, skipping all lookups in it.",
|
||||
"Directory 'tests/cases/conformance/node_modules' does not exist, skipping all lookups in it.",
|
||||
"Directory 'tests/cases/node_modules' does not exist, skipping all lookups in it.",
|
||||
@@ -41,11 +41,11 @@
|
||||
"Loading module 'ext/other' from 'node_modules' folder, target file type 'JavaScript'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"Module name 'other', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/other'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.js' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.jsx' does not exist.",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.js' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.jsx' does not exist.",
|
||||
"Directory 'tests/cases/conformance/node_modules' does not exist, skipping all lookups in it.",
|
||||
"Directory 'tests/cases/node_modules' does not exist, skipping all lookups in it.",
|
||||
"Directory 'tests/node_modules' does not exist, skipping all lookups in it.",
|
||||
|
||||
@@ -1,31 +1,31 @@
|
||||
=== tests/cases/conformance/moduleResolution/main.ts ===
|
||||
import { a } from "ext";
|
||||
>a : "ts3.0 a"
|
||||
>a : "ts3.1 a"
|
||||
|
||||
import { b } from "ext/other";
|
||||
>b : "ts3.0 b"
|
||||
>b : "ts3.1 b"
|
||||
|
||||
const aa: "ts3.0 a" = a;
|
||||
>aa : "ts3.0 a"
|
||||
>a : "ts3.0 a"
|
||||
const aa: "ts3.1 a" = a;
|
||||
>aa : "ts3.1 a"
|
||||
>a : "ts3.1 a"
|
||||
|
||||
const bb: "ts3.0 b" = b;
|
||||
>bb : "ts3.0 b"
|
||||
>b : "ts3.0 b"
|
||||
const bb: "ts3.1 b" = b;
|
||||
>bb : "ts3.1 b"
|
||||
>b : "ts3.1 b"
|
||||
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts ===
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts ===
|
||||
declare module "ext" {
|
||||
>"ext" : typeof import("ext")
|
||||
|
||||
export const a = "ts3.0 a";
|
||||
>a : "ts3.0 a"
|
||||
>"ts3.0 a" : "ts3.0 a"
|
||||
export const a = "ts3.1 a";
|
||||
>a : "ts3.1 a"
|
||||
>"ts3.1 a" : "ts3.1 a"
|
||||
}
|
||||
declare module "ext/other" {
|
||||
>"ext/other" : typeof import("ext/other")
|
||||
|
||||
export const b = "ts3.0 b";
|
||||
>b : "ts3.0 b"
|
||||
>"ts3.0 b" : "ts3.0 b"
|
||||
export const b = "ts3.1 b";
|
||||
>b : "ts3.1 b"
|
||||
>"ts3.1 b" : "ts3.1 b"
|
||||
}
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.0": { "*" : ["ts3.0/*"] }
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,17 +17,17 @@ export const a = "default a";
|
||||
export const b = "default b";
|
||||
|
||||
//// [index.d.ts]
|
||||
export const a = "ts3.0 a";
|
||||
export const a = "ts3.1 a";
|
||||
|
||||
//// [other.d.ts]
|
||||
export const b = "ts3.0 b";
|
||||
export const b = "ts3.1 b";
|
||||
|
||||
//// [main.ts]
|
||||
import { a } from "ext";
|
||||
import { b } from "ext/other";
|
||||
|
||||
const aa: "ts3.0 a" = a;
|
||||
const bb: "ts3.0 b" = b;
|
||||
const aa: "ts3.1 a" = a;
|
||||
const bb: "ts3.1 b" = b;
|
||||
|
||||
|
||||
//// [main.js]
|
||||
|
||||
@@ -6,12 +6,12 @@ export const a = "default a";
|
||||
export const b = "default b";
|
||||
>b : Symbol(b, Decl(other.d.ts, 0, 12))
|
||||
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts ===
|
||||
export const a = "ts3.0 a";
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts ===
|
||||
export const a = "ts3.1 a";
|
||||
>a : Symbol(a, Decl(index.d.ts, 0, 12))
|
||||
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.d.ts ===
|
||||
export const b = "ts3.0 b";
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts ===
|
||||
export const b = "ts3.1 b";
|
||||
>b : Symbol(b, Decl(other.d.ts, 0, 12))
|
||||
|
||||
=== tests/cases/conformance/moduleResolution/main.ts ===
|
||||
@@ -21,11 +21,11 @@ import { a } from "ext";
|
||||
import { b } from "ext/other";
|
||||
>b : Symbol(b, Decl(main.ts, 1, 8))
|
||||
|
||||
const aa: "ts3.0 a" = a;
|
||||
const aa: "ts3.1 a" = a;
|
||||
>aa : Symbol(aa, Decl(main.ts, 3, 5))
|
||||
>a : Symbol(a, Decl(main.ts, 0, 8))
|
||||
|
||||
const bb: "ts3.0 b" = b;
|
||||
const bb: "ts3.1 b" = b;
|
||||
>bb : Symbol(bb, Decl(main.ts, 4, 5))
|
||||
>b : Symbol(b, Decl(main.ts, 1, 8))
|
||||
|
||||
|
||||
@@ -11,27 +11,27 @@
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext.d.ts' does not exist.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/moduleResolution/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"Module name 'index', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/index'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts'. ========",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts'. ========",
|
||||
"======== Resolving module 'ext/other' from 'tests/cases/conformance/moduleResolution/main.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/moduleResolution/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"Module name 'other', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/other'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.d.ts'.",
|
||||
"======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.d.ts'. ========"
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts', result 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts'.",
|
||||
"======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts'. ========"
|
||||
]
|
||||
@@ -8,28 +8,28 @@ export const b = "default b";
|
||||
>b : "default b"
|
||||
>"default b" : "default b"
|
||||
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/index.d.ts ===
|
||||
export const a = "ts3.0 a";
|
||||
>a : "ts3.0 a"
|
||||
>"ts3.0 a" : "ts3.0 a"
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/index.d.ts ===
|
||||
export const a = "ts3.1 a";
|
||||
>a : "ts3.1 a"
|
||||
>"ts3.1 a" : "ts3.1 a"
|
||||
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.0/other.d.ts ===
|
||||
export const b = "ts3.0 b";
|
||||
>b : "ts3.0 b"
|
||||
>"ts3.0 b" : "ts3.0 b"
|
||||
=== tests/cases/conformance/moduleResolution/node_modules/ext/ts3.1/other.d.ts ===
|
||||
export const b = "ts3.1 b";
|
||||
>b : "ts3.1 b"
|
||||
>"ts3.1 b" : "ts3.1 b"
|
||||
|
||||
=== tests/cases/conformance/moduleResolution/main.ts ===
|
||||
import { a } from "ext";
|
||||
>a : "ts3.0 a"
|
||||
>a : "ts3.1 a"
|
||||
|
||||
import { b } from "ext/other";
|
||||
>b : "ts3.0 b"
|
||||
>b : "ts3.1 b"
|
||||
|
||||
const aa: "ts3.0 a" = a;
|
||||
>aa : "ts3.0 a"
|
||||
>a : "ts3.0 a"
|
||||
const aa: "ts3.1 a" = a;
|
||||
>aa : "ts3.1 a"
|
||||
>a : "ts3.1 a"
|
||||
|
||||
const bb: "ts3.0 b" = b;
|
||||
>bb : "ts3.0 b"
|
||||
>b : "ts3.0 b"
|
||||
const bb: "ts3.1 b" = b;
|
||||
>bb : "ts3.1 b"
|
||||
>b : "ts3.1 b"
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.0": { "*" : ["ts3.0/*"] }
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@ export const vb = fb();
|
||||
>vb : Symbol(vb, Decl(main.ts, 4, 12))
|
||||
>fb : Symbol(fb, Decl(main.ts, 1, 8))
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts ===
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts ===
|
||||
declare module "ext" {
|
||||
>"ext" : Symbol("ext", Decl(index.d.ts, 0, 0))
|
||||
|
||||
|
||||
@@ -11,27 +11,27 @@
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"Module name 'index', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/index'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts'. ========",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========",
|
||||
"======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"Module name 'other', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/other'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.d.ts' does not exist.",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' does not exist.",
|
||||
"Directory 'tests/cases/conformance/declarationEmit/node_modules/@types' does not exist, skipping all lookups in it.",
|
||||
"Directory 'tests/cases/conformance/node_modules' does not exist, skipping all lookups in it.",
|
||||
"Directory 'tests/cases/node_modules' does not exist, skipping all lookups in it.",
|
||||
@@ -41,11 +41,11 @@
|
||||
"Loading module 'ext/other' from 'node_modules' folder, target file type 'JavaScript'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"Module name 'other', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/other'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.js' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.jsx' does not exist.",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.js' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.jsx' does not exist.",
|
||||
"Directory 'tests/cases/conformance/node_modules' does not exist, skipping all lookups in it.",
|
||||
"Directory 'tests/cases/node_modules' does not exist, skipping all lookups in it.",
|
||||
"Directory 'tests/node_modules' does not exist, skipping all lookups in it.",
|
||||
|
||||
@@ -15,7 +15,7 @@ export const vb = fb();
|
||||
>fb() : import("ext/other").B
|
||||
>fb : () => import("ext/other").B
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts ===
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts ===
|
||||
declare module "ext" {
|
||||
>"ext" : typeof import("ext")
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.0": { "*" : ["ts3.0/*"] }
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ export function fb(): B;
|
||||
>fb : Symbol(fb, Decl(other.d.ts, 0, 21))
|
||||
>B : Symbol(B, Decl(other.d.ts, 0, 0))
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts ===
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts ===
|
||||
export interface A {}
|
||||
>A : Symbol(A, Decl(index.d.ts, 0, 0))
|
||||
|
||||
@@ -22,7 +22,7 @@ export function fa(): A;
|
||||
>fa : Symbol(fa, Decl(index.d.ts, 0, 21))
|
||||
>A : Symbol(A, Decl(index.d.ts, 0, 0))
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.d.ts ===
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts ===
|
||||
export interface B {}
|
||||
>B : Symbol(B, Decl(other.d.ts, 0, 0))
|
||||
|
||||
|
||||
@@ -11,27 +11,27 @@
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"Module name 'index', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/index'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts'. ========",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========",
|
||||
"======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.0' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"Module name 'other', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.0/*', candidate module location: 'ts3.0/other'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.d.ts'.",
|
||||
"======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.d.ts'. ========"
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'.",
|
||||
"======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'. ========"
|
||||
]
|
||||
@@ -8,30 +8,30 @@ export interface B {}
|
||||
export function fb(): B;
|
||||
>fb : () => B
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index.d.ts ===
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts ===
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
>fa : () => A
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other.d.ts ===
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts ===
|
||||
export interface B {}
|
||||
export function fb(): B;
|
||||
>fb : () => B
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/main.ts ===
|
||||
import { fa } from "ext";
|
||||
>fa : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index").A
|
||||
>fa : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index").A
|
||||
|
||||
import { fb } from "ext/other";
|
||||
>fb : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other").B
|
||||
>fb : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other").B
|
||||
|
||||
export const va = fa();
|
||||
>va : import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index").A
|
||||
>fa() : import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index").A
|
||||
>fa : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/index").A
|
||||
>va : import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index").A
|
||||
>fa() : import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index").A
|
||||
>fa : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index").A
|
||||
|
||||
export const vb = fb();
|
||||
>vb : import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other").B
|
||||
>fb() : import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other").B
|
||||
>fb : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.0/other").B
|
||||
>vb : import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other").B
|
||||
>fb() : import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other").B
|
||||
>fb : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other").B
|
||||
|
||||
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
tests/cases/conformance/declarationEmit/main.ts(1,10): error TS2305: Module '"tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index"' has no exported member 'fa'.
|
||||
|
||||
|
||||
==== tests/cases/conformance/declarationEmit/tsconfig.json (0 errors) ====
|
||||
{}
|
||||
==== tests/cases/conformance/declarationEmit/node_modules/ext/package.json (0 errors) ====
|
||||
{
|
||||
"name": "ext",
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
==== tests/cases/conformance/declarationEmit/node_modules/ext/index.d.ts (0 errors) ====
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
|
||||
==== tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts (0 errors) ====
|
||||
export interface B {}
|
||||
export function fb(): B;
|
||||
|
||||
==== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts (0 errors) ====
|
||||
export * from "../";
|
||||
|
||||
==== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts (0 errors) ====
|
||||
export * from "../other";
|
||||
|
||||
==== tests/cases/conformance/declarationEmit/main.ts (1 errors) ====
|
||||
import { fa } from "ext";
|
||||
~~
|
||||
!!! error TS2305: Module '"tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index"' has no exported member 'fa'.
|
||||
import { fb } from "ext/other";
|
||||
|
||||
export const va = fa();
|
||||
export const vb = fb();
|
||||
|
||||
+46
@@ -0,0 +1,46 @@
|
||||
//// [tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.ts] ////
|
||||
|
||||
//// [package.json]
|
||||
{
|
||||
"name": "ext",
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
//// [index.d.ts]
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
|
||||
//// [other.d.ts]
|
||||
export interface B {}
|
||||
export function fb(): B;
|
||||
|
||||
//// [index.d.ts]
|
||||
export * from "../";
|
||||
|
||||
//// [other.d.ts]
|
||||
export * from "../other";
|
||||
|
||||
//// [main.ts]
|
||||
import { fa } from "ext";
|
||||
import { fb } from "ext/other";
|
||||
|
||||
export const va = fa();
|
||||
export const vb = fb();
|
||||
|
||||
|
||||
//// [main.js]
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
const ext_1 = require("ext");
|
||||
const other_1 = require("ext/other");
|
||||
exports.va = ext_1.fa();
|
||||
exports.vb = other_1.fb();
|
||||
|
||||
|
||||
//// [main.d.ts]
|
||||
export declare const va: any;
|
||||
export declare const vb: import("ext/other").B;
|
||||
+37
@@ -0,0 +1,37 @@
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/index.d.ts ===
|
||||
export interface A {}
|
||||
>A : Symbol(A, Decl(index.d.ts, 0, 0))
|
||||
|
||||
export function fa(): A;
|
||||
>fa : Symbol(fa, Decl(index.d.ts, 0, 21))
|
||||
>A : Symbol(A, Decl(index.d.ts, 0, 0))
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts ===
|
||||
export interface B {}
|
||||
>B : Symbol(B, Decl(other.d.ts, 0, 0))
|
||||
|
||||
export function fb(): B;
|
||||
>fb : Symbol(fb, Decl(other.d.ts, 0, 21))
|
||||
>B : Symbol(B, Decl(other.d.ts, 0, 0))
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts ===
|
||||
export * from "../";
|
||||
No type information for this code.
|
||||
No type information for this code.=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts ===
|
||||
export * from "../other";
|
||||
No type information for this code.
|
||||
No type information for this code.=== tests/cases/conformance/declarationEmit/main.ts ===
|
||||
import { fa } from "ext";
|
||||
>fa : Symbol(fa, Decl(main.ts, 0, 8))
|
||||
|
||||
import { fb } from "ext/other";
|
||||
>fb : Symbol(fb, Decl(main.ts, 1, 8))
|
||||
|
||||
export const va = fa();
|
||||
>va : Symbol(va, Decl(main.ts, 3, 12))
|
||||
>fa : Symbol(fa, Decl(main.ts, 0, 8))
|
||||
|
||||
export const vb = fb();
|
||||
>vb : Symbol(vb, Decl(main.ts, 4, 12))
|
||||
>fb : Symbol(fb, Decl(main.ts, 1, 8))
|
||||
|
||||
+65
@@ -0,0 +1,65 @@
|
||||
[
|
||||
"======== Resolving module '../' from 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/', target file type 'TypeScript'.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/ndex/index.d.ts@1.0.0'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"Module name 'index', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.",
|
||||
"======== Module name '../' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========",
|
||||
"======== Resolving module '../other' from 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/other', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' exist - use it as a name resolution result.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other.d.ts@1.0.0'.",
|
||||
"======== Module name '../other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts'. ========",
|
||||
"======== Resolving module 'ext' from 'tests/cases/conformance/declarationEmit/main.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/index.d.ts@1.0.0'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"Module name 'index', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/index'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========",
|
||||
"======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"Module name 'other', matched pattern '*'.",
|
||||
"Trying substitution 'ts3.1/*', candidate module location: 'ts3.1/other'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'.",
|
||||
"======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts'. ========"
|
||||
]
|
||||
+33
@@ -0,0 +1,33 @@
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/index.d.ts ===
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
>fa : () => A
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts ===
|
||||
export interface B {}
|
||||
export function fb(): B;
|
||||
>fb : () => B
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts ===
|
||||
export * from "../";
|
||||
No type information for this code.
|
||||
No type information for this code.=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/other.d.ts ===
|
||||
export * from "../other";
|
||||
No type information for this code.
|
||||
No type information for this code.=== tests/cases/conformance/declarationEmit/main.ts ===
|
||||
import { fa } from "ext";
|
||||
>fa : any
|
||||
|
||||
import { fb } from "ext/other";
|
||||
>fb : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/other").B
|
||||
|
||||
export const va = fa();
|
||||
>va : any
|
||||
>fa() : any
|
||||
>fa : any
|
||||
|
||||
export const vb = fb();
|
||||
>vb : import("tests/cases/conformance/declarationEmit/node_modules/ext/other").B
|
||||
>fb() : import("tests/cases/conformance/declarationEmit/node_modules/ext/other").B
|
||||
>fb : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/other").B
|
||||
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
//// [tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.ts] ////
|
||||
|
||||
//// [package.json]
|
||||
{
|
||||
"name": "ext",
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.1": {
|
||||
"index" : ["ts3.1/index"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//// [index.d.ts]
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
|
||||
//// [other.d.ts]
|
||||
export interface A2 {}
|
||||
export function fa(): A2;
|
||||
|
||||
//// [index.d.ts]
|
||||
export * from "../other";
|
||||
|
||||
//// [main.ts]
|
||||
import { fa } from "ext";
|
||||
import { fa as fa2 } from "ext/other";
|
||||
|
||||
export const va = fa();
|
||||
export const va2 = fa2();
|
||||
|
||||
|
||||
//// [main.js]
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
const ext_1 = require("ext");
|
||||
const other_1 = require("ext/other");
|
||||
exports.va = ext_1.fa();
|
||||
exports.va2 = other_1.fa();
|
||||
|
||||
|
||||
//// [main.d.ts]
|
||||
export declare const va: import("ext/other").A2;
|
||||
export declare const va2: import("ext/other").A2;
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/index.d.ts ===
|
||||
export interface A {}
|
||||
>A : Symbol(A, Decl(index.d.ts, 0, 0))
|
||||
|
||||
export function fa(): A;
|
||||
>fa : Symbol(fa, Decl(index.d.ts, 0, 21))
|
||||
>A : Symbol(A, Decl(index.d.ts, 0, 0))
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts ===
|
||||
export interface A2 {}
|
||||
>A2 : Symbol(A2, Decl(other.d.ts, 0, 0))
|
||||
|
||||
export function fa(): A2;
|
||||
>fa : Symbol(fa, Decl(other.d.ts, 0, 22))
|
||||
>A2 : Symbol(A2, Decl(other.d.ts, 0, 0))
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts ===
|
||||
export * from "../other";
|
||||
No type information for this code.
|
||||
No type information for this code.=== tests/cases/conformance/declarationEmit/main.ts ===
|
||||
import { fa } from "ext";
|
||||
>fa : Symbol(fa, Decl(main.ts, 0, 8))
|
||||
|
||||
import { fa as fa2 } from "ext/other";
|
||||
>fa : Symbol(fa2, Decl(main.ts, 1, 8))
|
||||
>fa2 : Symbol(fa2, Decl(main.ts, 1, 8))
|
||||
|
||||
export const va = fa();
|
||||
>va : Symbol(va, Decl(main.ts, 3, 12))
|
||||
>fa : Symbol(fa, Decl(main.ts, 0, 8))
|
||||
|
||||
export const va2 = fa2();
|
||||
>va2 : Symbol(va2, Decl(main.ts, 4, 12))
|
||||
>fa2 : Symbol(fa2, Decl(main.ts, 1, 8))
|
||||
|
||||
+44
@@ -0,0 +1,44 @@
|
||||
[
|
||||
"======== Resolving module '../other' from 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/other', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' exist - use it as a name resolution result.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other.d.ts@1.0.0'.",
|
||||
"======== Module name '../other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts'. ========",
|
||||
"======== Resolving module 'ext' from 'tests/cases/conformance/declarationEmit/main.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module 'ext' from 'node_modules' folder, target file type 'TypeScript'.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/index.d.ts@1.0.0'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext.d.ts' does not exist.",
|
||||
"'package.json' does not have a 'typings' field.",
|
||||
"'package.json' has 'types' field 'index' that references 'tests/cases/conformance/declarationEmit/node_modules/ext/index'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'index'.",
|
||||
"Module name 'index', matched pattern 'index'.",
|
||||
"Trying substitution 'ts3.1/index', candidate module location: 'ts3.1/index'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index' does not exist.",
|
||||
"Loading module as file / folder, candidate module location 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index', target file type 'TypeScript'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'.",
|
||||
"======== Module name 'ext' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts'. ========",
|
||||
"======== Resolving module 'ext/other' from 'tests/cases/conformance/declarationEmit/main.ts'. ========",
|
||||
"Module resolution kind is not specified, using 'NodeJs'.",
|
||||
"Loading module 'ext/other' from 'node_modules' folder, target file type 'TypeScript'.",
|
||||
"'package.json' has a 'typesVersions' field with version-specific path mappings.",
|
||||
"Found 'package.json' at 'tests/cases/conformance/declarationEmit/node_modules/ext/package.json'. Package ID is 'ext/other/index.d.ts@1.0.0'.",
|
||||
"'package.json' has a 'typesVersions' entry '3.1' that matches compiler version '3.1', looking for a pattern to match module name 'other'.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.ts' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.tsx' does not exist.",
|
||||
"File 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts' exist - use it as a name resolution result.",
|
||||
"Resolving real path for 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts', result 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts'.",
|
||||
"======== Module name 'ext/other' was successfully resolved to 'tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts'. ========"
|
||||
]
|
||||
+31
@@ -0,0 +1,31 @@
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/index.d.ts ===
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
>fa : () => A
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/other.d.ts ===
|
||||
export interface A2 {}
|
||||
export function fa(): A2;
|
||||
>fa : () => A2
|
||||
|
||||
=== tests/cases/conformance/declarationEmit/node_modules/ext/ts3.1/index.d.ts ===
|
||||
export * from "../other";
|
||||
No type information for this code.
|
||||
No type information for this code.=== tests/cases/conformance/declarationEmit/main.ts ===
|
||||
import { fa } from "ext";
|
||||
>fa : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/other").A2
|
||||
|
||||
import { fa as fa2 } from "ext/other";
|
||||
>fa : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/other").A2
|
||||
>fa2 : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/other").A2
|
||||
|
||||
export const va = fa();
|
||||
>va : import("tests/cases/conformance/declarationEmit/node_modules/ext/other").A2
|
||||
>fa() : import("tests/cases/conformance/declarationEmit/node_modules/ext/other").A2
|
||||
>fa : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/other").A2
|
||||
|
||||
export const va2 = fa2();
|
||||
>va2 : import("tests/cases/conformance/declarationEmit/node_modules/ext/other").A2
|
||||
>fa2() : import("tests/cases/conformance/declarationEmit/node_modules/ext/other").A2
|
||||
>fa2 : () => import("tests/cases/conformance/declarationEmit/node_modules/ext/other").A2
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.0": { "*" : ["ts3.0/*"] }
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,7 +22,7 @@ declare module "ext/other" {
|
||||
export interface B {}
|
||||
export function fb(): B;
|
||||
}
|
||||
// @filename: node_modules/ext/ts3.0/index.d.ts
|
||||
// @filename: node_modules/ext/ts3.1/index.d.ts
|
||||
declare module "ext" {
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.0": { "*" : ["ts3.0/*"] }
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,11 +20,11 @@ export function fa(): A;
|
||||
export interface B {}
|
||||
export function fb(): B;
|
||||
|
||||
// @filename: node_modules/ext/ts3.0/index.d.ts
|
||||
// @filename: node_modules/ext/ts3.1/index.d.ts
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
|
||||
// @filename: node_modules/ext/ts3.0/other.d.ts
|
||||
// @filename: node_modules/ext/ts3.1/other.d.ts
|
||||
export interface B {}
|
||||
export function fb(): B;
|
||||
|
||||
|
||||
+37
@@ -0,0 +1,37 @@
|
||||
// @traceResolution: true
|
||||
// @target: esnext
|
||||
// @module: commonjs
|
||||
// @declaration: true
|
||||
// @filename: node_modules/ext/package.json
|
||||
{
|
||||
"name": "ext",
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
// @filename: node_modules/ext/index.d.ts
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
|
||||
// @filename: node_modules/ext/other.d.ts
|
||||
export interface B {}
|
||||
export function fb(): B;
|
||||
|
||||
// @filename: node_modules/ext/ts3.1/index.d.ts
|
||||
export * from "../";
|
||||
|
||||
// @filename: node_modules/ext/ts3.1/other.d.ts
|
||||
export * from "../other";
|
||||
|
||||
// @filename: main.ts
|
||||
import { fa } from "ext";
|
||||
import { fb } from "ext/other";
|
||||
|
||||
export const va = fa();
|
||||
export const vb = fb();
|
||||
|
||||
// @filename: tsconfig.json
|
||||
{}
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
// @traceResolution: true
|
||||
// @target: esnext
|
||||
// @module: commonjs
|
||||
// @declaration: true
|
||||
// @filename: node_modules/ext/package.json
|
||||
{
|
||||
"name": "ext",
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.1": {
|
||||
"index" : ["ts3.1/index"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// @filename: node_modules/ext/index.d.ts
|
||||
export interface A {}
|
||||
export function fa(): A;
|
||||
|
||||
// @filename: node_modules/ext/other.d.ts
|
||||
export interface A2 {}
|
||||
export function fa(): A2;
|
||||
|
||||
// @filename: node_modules/ext/ts3.1/index.d.ts
|
||||
export * from "../other";
|
||||
|
||||
// @filename: main.ts
|
||||
import { fa } from "ext";
|
||||
import { fa as fa2 } from "ext/other";
|
||||
|
||||
export const va = fa();
|
||||
export const va2 = fa2();
|
||||
|
||||
// @filename: tsconfig.json
|
||||
{}
|
||||
@@ -8,7 +8,7 @@
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.0": { "*" : ["ts3.0/*"] }
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,20 +20,20 @@ declare module "ext/other" {
|
||||
export const b = "default b";
|
||||
}
|
||||
|
||||
// @filename: node_modules/ext/ts3.0/index.d.ts
|
||||
// @filename: node_modules/ext/ts3.1/index.d.ts
|
||||
declare module "ext" {
|
||||
export const a = "ts3.0 a";
|
||||
export const a = "ts3.1 a";
|
||||
}
|
||||
declare module "ext/other" {
|
||||
export const b = "ts3.0 b";
|
||||
export const b = "ts3.1 b";
|
||||
}
|
||||
|
||||
// @filename: main.ts
|
||||
import { a } from "ext";
|
||||
import { b } from "ext/other";
|
||||
|
||||
const aa: "ts3.0 a" = a;
|
||||
const bb: "ts3.0 b" = b;
|
||||
const aa: "ts3.1 a" = a;
|
||||
const bb: "ts3.1 b" = b;
|
||||
|
||||
// @filename: tsconfig.json
|
||||
{}
|
||||
@@ -7,7 +7,7 @@
|
||||
"version": "1.0.0",
|
||||
"types": "index",
|
||||
"typesVersions": {
|
||||
"3.0": { "*" : ["ts3.0/*"] }
|
||||
"3.1": { "*" : ["ts3.1/*"] }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,18 +17,18 @@ export const a = "default a";
|
||||
// @filename: node_modules/ext/other.d.ts
|
||||
export const b = "default b";
|
||||
|
||||
// @filename: node_modules/ext/ts3.0/index.d.ts
|
||||
export const a = "ts3.0 a";
|
||||
// @filename: node_modules/ext/ts3.1/index.d.ts
|
||||
export const a = "ts3.1 a";
|
||||
|
||||
// @filename: node_modules/ext/ts3.0/other.d.ts
|
||||
export const b = "ts3.0 b";
|
||||
// @filename: node_modules/ext/ts3.1/other.d.ts
|
||||
export const b = "ts3.1 b";
|
||||
|
||||
// @filename: main.ts
|
||||
import { a } from "ext";
|
||||
import { b } from "ext/other";
|
||||
|
||||
const aa: "ts3.0 a" = a;
|
||||
const bb: "ts3.0 b" = b;
|
||||
const aa: "ts3.1 a" = a;
|
||||
const bb: "ts3.1 b" = b;
|
||||
|
||||
// @filename: tsconfig.json
|
||||
{}
|
||||
Reference in New Issue
Block a user