/third_party/typescript/tests/baselines/reference/ |
D | prespecializedGenericMembers1.types | 6 export class Cat<CatType extends IKitty> { 7 >Cat : Cat<CatType> 17 constructor(cats: { barry: Cat<IKitty>; }) { 18 >cats : { barry: Cat<IKitty>; } 19 >barry : Cat<IKitty> 23 var cat = new Cat<IKitty>(); 24 >cat : Cat<IKitty> 25 >new Cat<IKitty>() : Cat<IKitty> 26 >Cat : typeof Cat 29 >catThing : { barry: Cat<IKitty>; } [all …]
|
D | tsxUnionSpread.types | 6 export type CatInfo = { type: 'Cat'; subType: string; }; 7 >CatInfo : { type: 'Cat'; subType: string; } 8 >type : "Cat" 32 return { type: 'Cat', subType: 'Large' }; 33 >{ type: 'Cat', subType: 'Large' } : { type: "Cat"; subType: string; } 34 >type : "Cat" 35 >'Cat' : "Cat" 51 var props2:AnimalInfo = { type: 'Cat', subType: 'Large' }; 53 >{ type: 'Cat', subType: 'Large' } : { type: "Cat"; subType: string; } 54 >type : "Cat" [all …]
|
D | functionOverloads45.types | 8 interface Cat extends Animal { cat } 11 function foo1(bar: { a:number }[]): Cat; 12 >foo1 : { (bar: { a: number;}[]): Cat; (bar: { a: string; }[]): Dog; } 17 >foo1 : { (bar: { a: number; }[]): Cat; (bar: { a: string;}[]): Dog; } 22 >foo1 : { (bar: { a: number; }[]): Cat; (bar: { a: string; }[]): Dog; } 30 function foo2(bar: { a:number }[]): Cat; 31 >foo2 : { (bar: { a: number;}[]): Cat; (bar: { a: string; }[]): Dog; } 36 >foo2 : { (bar: { a: number; }[]): Cat; (bar: { a: string;}[]): Dog; } 40 function foo2([x]: { a:number | string }[]): Cat | Dog { 41 >foo2 : { (bar: { a: number; }[]): Cat; (bar: { a: string; }[]): Dog; } [all …]
|
D | functionOverloads44.types | 8 interface Cat extends Animal { cat } 30 function foo2(bar: { a:number }[]): Cat; 31 >foo2 : { (bar: { a: number;}[]): Cat; (bar: { a: string; }[]): Dog | Cat; } 35 function foo2(bar: { a:string }[]): Cat | Dog; 36 >foo2 : { (bar: { a: number; }[]): Cat; (bar: { a: string;}[]): Cat | Dog; } 40 function foo2([x]: { a:number | string }[]): Cat { 41 >foo2 : { (bar: { a: number; }[]): Cat; (bar: { a: string; }[]): Dog | Cat; } 69 >x2 : Dog | Cat 70 >foo2([{a: "str"}]) : Dog | Cat 71 >foo2 : { (bar: { a: number; }[]): Cat; (bar: { a: string; }[]): Dog | Cat; } [all …]
|
D | typeParameterExtendingUnion2.types | 6 class Cat extends Animal { meow } 7 >Cat : Cat 16 function run(a: Cat | Dog) { 17 >run : (a: Cat | Dog) => void 18 >a : Cat | Dog 23 >a : Cat | Dog 27 function f<T extends Cat | Dog>(a: T) { 28 >f : <T extends Cat | Dog>(a: T) => void 34 >a : Cat | Dog 39 >run : (a: Cat | Dog) => void [all …]
|
D | prespecializedGenericMembers1.js | 6 export class Cat<CatType extends IKitty> { class 13 constructor(cats: { barry: Cat<IKitty>; }) { 17 var cat = new Cat<IKitty>(); 26 exports.CatBag = exports.Cat = void 0; 27 var Cat = /** @class */ (function () { 28 function Cat() { class in Cat 30 return Cat; 32 exports.Cat = Cat; 39 var cat = new Cat();
|
D | prespecializedGenericMembers1.symbols | 7 export class Cat<CatType extends IKitty> { 8 >Cat : Symbol(Cat, Decl(prespecializedGenericMembers1.ts, 2, 5)) 20 constructor(cats: { barry: Cat<IKitty>; }) { 23 >Cat : Symbol(Cat, Decl(prespecializedGenericMembers1.ts, 2, 5)) 28 var cat = new Cat<IKitty>(); 30 >Cat : Symbol(Cat, Decl(prespecializedGenericMembers1.ts, 2, 5))
|
D | typeParameterExtendingUnion2.symbols | 6 class Cat extends Animal { meow } 7 >Cat : Symbol(Cat, Decl(typeParameterExtendingUnion2.ts, 0, 26)) 9 >meow : Symbol(Cat.meow, Decl(typeParameterExtendingUnion2.ts, 1, 26)) 16 function run(a: Cat | Dog) { 19 >Cat : Symbol(Cat, Decl(typeParameterExtendingUnion2.ts, 0, 26)) 28 function f<T extends Cat | Dog>(a: T) { 31 >Cat : Symbol(Cat, Decl(typeParameterExtendingUnion2.ts, 0, 26))
|
D | assertionFunctionsCanNarrowByDiscriminant.symbols | 2 interface Cat { 3 >Cat : Symbol(Cat, Decl(assertionFunctionsCanNarrowByDiscriminant.ts, 0, 0)) 6 >type : Symbol(Cat.type, Decl(assertionFunctionsCanNarrowByDiscriminant.ts, 0, 15)) 9 >canMeow : Symbol(Cat.canMeow, Decl(assertionFunctionsCanNarrowByDiscriminant.ts, 1, 16)) 22 type Animal = Cat | Dog; 24 >Cat : Symbol(Cat, Decl(assertionFunctionsCanNarrowByDiscriminant.ts, 0, 0)) 50 >animal.canMeow : Symbol(Cat.canMeow, Decl(assertionFunctionsCanNarrowByDiscriminant.ts, 1, 16)) 52 >canMeow : Symbol(Cat.canMeow, Decl(assertionFunctionsCanNarrowByDiscriminant.ts, 1, 16)) 68 >animalOrUndef.canMeow : Symbol(Cat.canMeow, Decl(assertionFunctionsCanNarrowByDiscriminant.ts, 1, … 70 >canMeow : Symbol(Cat.canMeow, Decl(assertionFunctionsCanNarrowByDiscriminant.ts, 1, 16))
|
D | functionOverloads45.symbols | 11 interface Cat extends Animal { cat } 12 >Cat : Symbol(Cat, Decl(functionOverloads45.ts, 1, 36)) 14 >cat : Symbol(Cat.cat, Decl(functionOverloads45.ts, 2, 30)) 16 function foo1(bar: { a:number }[]): Cat; 20 >Cat : Symbol(Cat, Decl(functionOverloads45.ts, 1, 36)) 38 function foo2(bar: { a:number }[]): Cat; 42 >Cat : Symbol(Cat, Decl(functionOverloads45.ts, 1, 36)) 50 function foo2([x]: { a:number | string }[]): Cat | Dog { 54 >Cat : Symbol(Cat, Decl(functionOverloads45.ts, 1, 36))
|
D | functionOverloads44.symbols | 11 interface Cat extends Animal { cat } 12 >Cat : Symbol(Cat, Decl(functionOverloads44.ts, 1, 36)) 14 >cat : Symbol(Cat.cat, Decl(functionOverloads44.ts, 2, 30)) 38 function foo2(bar: { a:number }[]): Cat; 42 >Cat : Symbol(Cat, Decl(functionOverloads44.ts, 1, 36)) 44 function foo2(bar: { a:string }[]): Cat | Dog; 48 >Cat : Symbol(Cat, Decl(functionOverloads44.ts, 1, 36)) 51 function foo2([x]: { a:number | string }[]): Cat { 55 >Cat : Symbol(Cat, Decl(functionOverloads44.ts, 1, 36))
|
D | typeParameterExtendingUnion1.types | 6 class Cat extends Animal { meow } 7 >Cat : Cat 27 function f<T extends Cat | Dog>(a: T) { 28 >f : <T extends Cat | Dog>(a: T) => void 34 >a : Cat | Dog 40 >a : Cat | Dog
|
D | typeParameterExtendingUnion2.js | 3 class Cat extends Animal { meow } class 6 function run(a: Cat | Dog) { 10 function f<T extends Cat | Dog>(a: T) { 37 var Cat = /** @class */ (function (_super) { 38 __extends(Cat, _super); 39 function Cat() { class in Cat 42 return Cat;
|
D | enumExportMergingES6.symbols | 5 Cat = 1 6 >Cat : Symbol(Animals.Cat, Decl(enumExportMergingES6.ts, 0, 21)) 17 CatDog = Cat | Dog 19 >Cat : Symbol(Animals.Cat, Decl(enumExportMergingES6.ts, 0, 21))
|
D | enumExportMergingES6.types | 5 Cat = 1 6 >Cat : Animals 19 CatDog = Cat | Dog 21 >Cat | Dog : number 22 >Cat : Animals
|
D | stringLiteralTypesOverloads05.types | 8 interface Cat extends Animal { cat: {} } 15 >doThing : { (x: "dog"): Dog; (x: "cat"): Cat; (x: string): Animal; } 18 function doThing(x: "cat"): Cat; 19 >doThing : { (x: "dog"): Dog; (x: "cat"): Cat; (x: string): Animal; } 23 >doThing : { (x: "dog"): Dog; (x: "cat"): Cat; (x: string): Animal; } 27 >doThing : { (x: "dog"): Dog; (x: "cat"): Cat; (x: string): Animal; }
|
D | typeParameterExtendingUnion1.js | 3 class Cat extends Animal { meow } class 10 function f<T extends Cat | Dog>(a: T) { 37 var Cat = /** @class */ (function (_super) { 38 __extends(Cat, _super); 39 function Cat() { class in Cat 42 return Cat;
|
D | typeParameterExtendingUnion1.symbols | 6 class Cat extends Animal { meow } 7 >Cat : Symbol(Cat, Decl(typeParameterExtendingUnion1.ts, 0, 26)) 9 >meow : Symbol(Cat.meow, Decl(typeParameterExtendingUnion1.ts, 1, 26)) 27 function f<T extends Cat | Dog>(a: T) { 30 >Cat : Symbol(Cat, Decl(typeParameterExtendingUnion1.ts, 0, 26))
|
D | stringLiteralTypesOverloads05.symbols | 11 interface Cat extends Animal { cat: {} } 12 >Cat : Symbol(Cat, Decl(stringLiteralTypesOverloads05.ts, 1, 40)) 14 >cat : Symbol(Cat.cat, Decl(stringLiteralTypesOverloads05.ts, 2, 30)) 26 function doThing(x: "cat"): Cat; 29 >Cat : Symbol(Cat, Decl(stringLiteralTypesOverloads05.ts, 1, 40))
|
D | stringLiteralTypesOverloads05.js | 4 interface Cat extends Animal { cat: {} } 8 function doThing(x: "cat"): Cat; 28 interface Cat extends Animal { 35 declare function doThing(x: "cat"): Cat;
|
D | functionOverloads44.js | 4 interface Cat extends Animal { cat } 12 function foo2(bar: { a:number }[]): Cat; 13 function foo2(bar: { a:string }[]): Cat | Dog; 14 function foo2([x]: { a:number | string }[]): Cat {
|
D | functionOverloads45.js | 4 interface Cat extends Animal { cat } 6 function foo1(bar: { a:number }[]): Cat; 12 function foo2(bar: { a:number }[]): Cat; 14 function foo2([x]: { a:number | string }[]): Cat | Dog {
|
/third_party/typescript/tests/cases/compiler/ |
D | functionOverloads44.ts | 3 interface Cat extends Animal { cat } interface 11 function foo2(bar: { a:number }[]): Cat; 12 function foo2(bar: { a:string }[]): Cat | Dog; 13 function foo2([x]: { a:number | string }[]): Cat {
|
D | functionOverloads45.ts | 3 interface Cat extends Animal { cat } interface 5 function foo1(bar: { a:number }[]): Cat; 11 function foo2(bar: { a:number }[]): Cat; 13 function foo2([x]: { a:number | string }[]): Cat | Dog {
|
D | prespecializedGenericMembers1.ts | 6 export class Cat<CatType extends IKitty> { class 13 constructor(cats: { barry: Cat<IKitty>; }) { 17 var cat = new Cat<IKitty>();
|