/third_party/typescript/tests/baselines/reference/ |
D | tsxTypeArgumentsJsxPreserveOutput.types | 12 function Foo<T>() { 13 >Foo : <T>() => any 20 …Foo<unknown> /> <Foo<string> /> <Foo<boolean> /> <Foo<object> /> <Foo<null> /> <Foo… 23 <Foo<unknown> /> 24 ><Foo<unknown> /> : JSX.Element 25 >Foo : <T>() => any 27 <Foo<string> /> 28 ><Foo<string> /> : JSX.Element 29 >Foo : <T>() => any 31 <Foo<boolean> /> [all …]
|
D | tsxTypeArgumentsJsxPreserveOutput.js | 7 function Foo<T>() { 13 <Foo<unknown> /> 14 <Foo<string> /> 15 <Foo<boolean> /> 16 <Foo<object> /> 17 <Foo<null> /> 18 <Foo<any> /> 19 <Foo<never> /> 20 <Foo<undefined> /> 21 <Foo<TypeProps> /> [all …]
|
D | tsxTypeArgumentsJsxPreserveOutput.symbols | 13 function Foo<T>() { 14 >Foo : Symbol(Foo, Decl(foo.tsx, 3, 43)) 22 <Foo<unknown> /> 23 >Foo : Symbol(Foo, Decl(foo.tsx, 3, 43)) 25 <Foo<string> /> 26 >Foo : Symbol(Foo, Decl(foo.tsx, 3, 43)) 28 <Foo<boolean> /> 29 >Foo : Symbol(Foo, Decl(foo.tsx, 3, 43)) 31 <Foo<object> /> 32 >Foo : Symbol(Foo, Decl(foo.tsx, 3, 43)) [all …]
|
D | constEnumToStringWithComments.types | 2 const enum Foo { 3 >Foo : Foo 6 >X : Foo.X 10 >Y : Foo.Y 14 >Z : Foo.Z 18 >A : Foo.A 23 >B : Foo.B 28 >C : Foo.A 33 let x0 = Foo.X.toString(); 35 >Foo.X.toString() : string [all …]
|
D | constEnumToStringNoComments.types | 2 const enum Foo { 3 >Foo : Foo 6 >X : Foo.X 10 >Y : Foo.Y 14 >Z : Foo.Z 18 >A : Foo.A 23 >B : Foo.B 28 >C : Foo.A 33 let x0 = Foo.X.toString(); 35 >Foo.X.toString() : string [all …]
|
D | enumLiteralAssignableToEnumInsideUnion.types | 5 export enum Foo { 6 >Foo : Foo 9 >A : Foo.A 10 >B : Foo.B 16 export enum Foo { 17 >Foo : Foo 20 >A : Foo.A 21 >B : Foo.B 27 export enum Foo { 28 >Foo : Foo [all …]
|
D | classBlockScoping.types | 6 let Foo: any; 7 >Foo : any 12 Foo = class Foo { 13 >Foo = class Foo { static y = new Foo(); static x() { new Foo(); } m() {… 14 >Foo : any 15 >class Foo { static y = new Foo(); static x() { new Foo(); } m() { … 16 >Foo : typeof Foo 18 static y = new Foo(); 19 >y : Foo 20 >new Foo() : Foo [all …]
|
D | enumLiteralAssignableToEnumInsideUnion.js | 3 export enum Foo { 8 export enum Foo { 13 export enum Foo { 19 export enum Foo { 24 const e0: X.Foo | boolean = Y.Foo.A; // ok 25 const e1: X.Foo | boolean = Z.Foo.A; // not legal, Z is computed 26 const e2: X.Foo.A | X.Foo.B | boolean = Z.Foo.A; // still not legal 27 const e3: X.Foo.B | boolean = Z.Foo.A; // not legal 28 const e4: X.Foo.A | boolean = Z.Foo.A; // not legal either because Z.Foo is computed and Z.Foo.A is… 29 const e5: Ka.Foo | boolean = Z.Foo.A; // ok [all …]
|
D | subtypesOfTypeParameterWithRecursiveConstraints.types | 4 class Foo<T> { foo: T; } 5 >Foo : Foo<T> 8 function f<T extends Foo<U>, U extends Foo<T>, V extends Foo<V>>(t: T, u: U, v: V) { 9 >f : <T extends Foo<U>, U extends Foo<T>, V extends Foo<V>>(t: T, u: U, v: V) => void 60 var r4 = true ? t : new Foo<T>(); 61 >r4 : T | Foo<T> 62 >true ? t : new Foo<T>() : T | Foo<T> 65 >new Foo<T>() : Foo<T> 66 >Foo : typeof Foo 68 var r4 = true ? new Foo<T>() : t; [all …]
|
D | enumLiteralAssignableToEnumInsideUnion.symbols | 5 export enum Foo { 6 >Foo : Symbol(Foo, Decl(enumLiteralAssignableToEnumInsideUnion.ts, 0, 10)) 9 >A : Symbol(Foo.A, Decl(enumLiteralAssignableToEnumInsideUnion.ts, 1, 21)) 10 >B : Symbol(Foo.B, Decl(enumLiteralAssignableToEnumInsideUnion.ts, 2, 10)) 16 export enum Foo { 17 >Foo : Symbol(Foo, Decl(enumLiteralAssignableToEnumInsideUnion.ts, 5, 10)) 20 >A : Symbol(Foo.A, Decl(enumLiteralAssignableToEnumInsideUnion.ts, 6, 21)) 21 >B : Symbol(Foo.B, Decl(enumLiteralAssignableToEnumInsideUnion.ts, 7, 10)) 27 export enum Foo { 28 >Foo : Symbol(Foo, Decl(enumLiteralAssignableToEnumInsideUnion.ts, 10, 10)) [all …]
|
D | classBlockScoping.symbols | 6 let Foo: any; 7 >Foo : Symbol(Foo, Decl(classBlockScoping.ts, 1, 5)) 12 Foo = class Foo { 13 >Foo : Symbol(Foo, Decl(classBlockScoping.ts, 1, 5)) 14 >Foo : Symbol(Foo, Decl(classBlockScoping.ts, 3, 9)) 16 static y = new Foo(); 17 >y : Symbol(Foo.y, Decl(classBlockScoping.ts, 3, 21)) 18 >Foo : Symbol(Foo, Decl(classBlockScoping.ts, 3, 9)) 21 >x : Symbol(Foo.x, Decl(classBlockScoping.ts, 4, 27)) 23 new Foo(); [all …]
|
D | subtypesOfTypeParameterWithRecursiveConstraints.js | 4 class Foo<T> { foo: T; } class 5 function f<T extends Foo<U>, U extends Foo<T>, V extends Foo<V>>(t: T, u: U, v: V) { 19 var r4 = true ? t : new Foo<T>(); 20 var r4 = true ? new Foo<T>() : t; 23 var r5 = true ? u : new Foo<T>(); 24 var r5 = true ? new Foo<T>() : u; 27 var r6 = true ? v : new Foo<T>(); 28 var r6 = true ? new Foo<T>() : v; 32 var r7 = true ? t : new Foo<U>(); 33 var r7 = true ? new Foo<U>() : t; [all …]
|
D | classBlockScoping.js | 3 let Foo: any; 5 Foo = class Foo { class 6 static y = new Foo(); 9 new Foo(); 13 new Foo(); 17 new Foo(); 20 class Foo { 21 static y = new Foo(); 24 new Foo(); 28 new Foo(); [all …]
|
D | subtypesOfTypeParameterWithConstraints4.types | 4 class Foo { foo: number; } 5 >Foo : Foo 8 function f<T extends Foo, U extends Foo, V>(t: T, u: U, v: V) { 9 >f : <T extends Foo, U extends Foo, V>(t: T, u: U, v: V) => void 60 var r4 = true ? t : new Foo(); 61 >r4 : Foo 62 >true ? t : new Foo() : Foo 65 >new Foo() : Foo 66 >Foo : typeof Foo 68 var r4 = true ? new Foo() : t; [all …]
|
D | constEnumToStringNoComments.symbols | 2 const enum Foo { 3 >Foo : Symbol(Foo, Decl(constEnumToStringNoComments.ts, 0, 0)) 6 >X : Symbol(Foo.X, Decl(constEnumToStringNoComments.ts, 0, 16)) 9 >Y : Symbol(Foo.Y, Decl(constEnumToStringNoComments.ts, 1, 12)) 12 >Z : Symbol(Foo.Z, Decl(constEnumToStringNoComments.ts, 2, 12)) 15 >A : Symbol(Foo.A, Decl(constEnumToStringNoComments.ts, 3, 11)) 18 >B : Symbol(Foo.B, Decl(constEnumToStringNoComments.ts, 4, 11)) 21 >C : Symbol(Foo.C, Decl(constEnumToStringNoComments.ts, 5, 13)) 24 let x0 = Foo.X.toString(); 26 >Foo.X.toString : Symbol(Number.toString, Decl(lib.es5.d.ts, --, --)) [all …]
|
D | constEnumToStringWithComments.symbols | 2 const enum Foo { 3 >Foo : Symbol(Foo, Decl(constEnumToStringWithComments.ts, 0, 0)) 6 >X : Symbol(Foo.X, Decl(constEnumToStringWithComments.ts, 0, 16)) 9 >Y : Symbol(Foo.Y, Decl(constEnumToStringWithComments.ts, 1, 12)) 12 >Z : Symbol(Foo.Z, Decl(constEnumToStringWithComments.ts, 2, 12)) 15 >A : Symbol(Foo.A, Decl(constEnumToStringWithComments.ts, 3, 11)) 18 >B : Symbol(Foo.B, Decl(constEnumToStringWithComments.ts, 4, 11)) 21 >C : Symbol(Foo.C, Decl(constEnumToStringWithComments.ts, 5, 13)) 24 let x0 = Foo.X.toString(); 26 >Foo.X.toString : Symbol(Number.toString, Decl(lib.es5.d.ts, --, --)) [all …]
|
D | constructorOverloads1.types | 2 class Foo { 3 >Foo : Foo 26 var f1 = new Foo("hey"); 27 >f1 : Foo 28 >new Foo("hey") : Foo 29 >Foo : typeof Foo 32 var f2 = new Foo(0); 33 >f2 : Foo 34 >new Foo(0) : Foo 35 >Foo : typeof Foo [all …]
|
D | callOverloads3.types | 2 function Foo():Foo; // error 3 >Foo : typeof Foo 5 function Foo(s:string):Foo; // error 6 >Foo : typeof Foo 9 class Foo { // error 10 >Foo : Foo 21 //class Foo(s: String); 23 var f1 = new Foo("hey"); 24 >f1 : Foo 25 >new Foo("hey") : Foo [all …]
|
D | tsxEmit3.types | 10 export class Foo { constructor() { } } 11 >Foo : Foo 19 // Emit Foo 20 // Foo, <Foo />; 27 // Emit M.Foo 28 Foo, <Foo />; 29 >Foo, <Foo /> : JSX.Element 30 >Foo : typeof Foo 31 ><Foo /> : JSX.Element 32 >Foo : typeof Foo [all …]
|
D | constructorOverloads6.types | 19 declare class Foo extends FooBase { 20 >Foo : Foo 37 var f1 = new Foo("hey"); 38 >f1 : Foo 39 >new Foo("hey") : Foo 40 >Foo : typeof Foo 43 var f2 = new Foo(0); 44 >f2 : Foo 45 >new Foo(0) : Foo 46 >Foo : typeof Foo [all …]
|
D | constructorOverloads3.types | 16 class Foo extends FooBase { 17 >Foo : Foo 37 var f1 = new Foo("hey"); 38 >f1 : Foo 39 >new Foo("hey") : Foo 40 >Foo : typeof Foo 43 var f2 = new Foo(0); 44 >f2 : Foo 45 >new Foo(0) : Foo 46 >Foo : typeof Foo [all …]
|
D | callOverloads4.types | 2 function Foo():Foo; // error 3 >Foo : typeof Foo 5 function Foo(s:string):Foo; // error 6 >Foo : typeof Foo 9 class Foo { // error 10 >Foo : Foo 25 var f1 = new Foo("hey"); 26 >f1 : Foo 27 >new Foo("hey") : Foo 28 >Foo : typeof Foo [all …]
|
D | constructorOverloads2.types | 18 class Foo extends FooBase { 19 >Foo : Foo 44 var f1 = new Foo("hey"); 45 >f1 : Foo 46 >new Foo("hey") : Foo 47 >Foo : typeof Foo 50 var f2 = new Foo(0); 51 >f2 : Foo 52 >new Foo(0) : Foo 53 >Foo : typeof Foo [all …]
|
/third_party/typescript/tests/cases/conformance/types/typeRelationships/subtypesAndSuperTypes/ |
D | subtypesOfTypeParameterWithRecursiveConstraints.ts | 3 class Foo<T> { foo: T; } class 4 function f<T extends Foo<U>, U extends Foo<T>, V extends Foo<V>>(t: T, u: U, v: V) { 18 var r4 = true ? t : new Foo<T>(); 19 var r4 = true ? new Foo<T>() : t; 22 var r5 = true ? u : new Foo<T>(); 23 var r5 = true ? new Foo<T>() : u; 26 var r6 = true ? v : new Foo<T>(); 27 var r6 = true ? new Foo<T>() : v; 31 var r7 = true ? t : new Foo<U>(); 32 var r7 = true ? new Foo<U>() : t; [all …]
|
/third_party/typescript/tests/cases/conformance/jsx/ |
D | tsxTypeArgumentsJsxPreserveOutput.tsx | 12 function Foo<T>() { 18 <Foo<unknown> /> 19 <Foo<string> /> 20 <Foo<boolean> /> 21 <Foo<object> /> 22 <Foo<null> /> 23 <Foo<any> /> 24 <Foo<never> /> 25 <Foo<undefined> /> 26 <Foo<TypeProps> /> [all …]
|