1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
|
=== tests/cases/conformance/jsx/file.tsx ===
declare module JSX {
>JSX : Symbol(JSX, Decl(file.tsx, 0, 0))
interface Element { something; }
>Element : Symbol(Element, Decl(file.tsx, 0, 20))
>something : Symbol(Element.something, Decl(file.tsx, 1, 20))
interface IntrinsicElements { }
>IntrinsicElements : Symbol(IntrinsicElements, Decl(file.tsx, 1, 33))
}
interface Obj1 {
>Obj1 : Symbol(Obj1, Decl(file.tsx, 3, 1), Decl(file.tsx, 9, 3))
new(n: string): { x: number };
>n : Symbol(n, Decl(file.tsx, 6, 5))
>x : Symbol(x, Decl(file.tsx, 6, 18))
new(n: number): { y: string };
>n : Symbol(n, Decl(file.tsx, 7, 5))
>y : Symbol(y, Decl(file.tsx, 7, 18))
}
var Obj1: Obj1;
>Obj1 : Symbol(Obj1, Decl(file.tsx, 3, 1), Decl(file.tsx, 9, 3))
>Obj1 : Symbol(Obj1, Decl(file.tsx, 3, 1), Decl(file.tsx, 9, 3))
<Obj1 />; // Error, return type is not an object type
>Obj1 : Symbol(Obj1, Decl(file.tsx, 3, 1), Decl(file.tsx, 9, 3))
interface Obj2 {
>Obj2 : Symbol(Obj2, Decl(file.tsx, 10, 9), Decl(file.tsx, 16, 3))
(n: string): { x: number };
>n : Symbol(n, Decl(file.tsx, 13, 2))
>x : Symbol(x, Decl(file.tsx, 13, 15))
(n: number): { y: string };
>n : Symbol(n, Decl(file.tsx, 14, 2))
>y : Symbol(y, Decl(file.tsx, 14, 15))
}
var Obj2: Obj2;
>Obj2 : Symbol(Obj2, Decl(file.tsx, 10, 9), Decl(file.tsx, 16, 3))
>Obj2 : Symbol(Obj2, Decl(file.tsx, 10, 9), Decl(file.tsx, 16, 3))
<Obj2 />; // Error, return type is not an object type
>Obj2 : Symbol(Obj2, Decl(file.tsx, 10, 9), Decl(file.tsx, 16, 3))
interface Obj3 {
>Obj3 : Symbol(Obj3, Decl(file.tsx, 17, 9), Decl(file.tsx, 23, 3))
(n: string): { x: number };
>n : Symbol(n, Decl(file.tsx, 20, 2))
>x : Symbol(x, Decl(file.tsx, 20, 15))
(n: number): { x: number; y: string };
>n : Symbol(n, Decl(file.tsx, 21, 2))
>x : Symbol(x, Decl(file.tsx, 21, 15))
>y : Symbol(y, Decl(file.tsx, 21, 26))
}
var Obj3: Obj3;
>Obj3 : Symbol(Obj3, Decl(file.tsx, 17, 9), Decl(file.tsx, 23, 3))
>Obj3 : Symbol(Obj3, Decl(file.tsx, 17, 9), Decl(file.tsx, 23, 3))
<Obj3 x={42} />; // OK
>Obj3 : Symbol(Obj3, Decl(file.tsx, 17, 9), Decl(file.tsx, 23, 3))
>x : Symbol(unknown)
|