File: tsxUnionElementType4.symbols

package info (click to toggle)
node-typescript 4.9.5%2Bds1-2
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 533,908 kB
  • sloc: javascript: 2,018,330; makefile: 7; sh: 1
file content (91 lines) | stat: -rw-r--r-- 3,055 bytes parent folder | download | duplicates (5)
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
=== tests/cases/conformance/jsx/file.tsx ===
import React = require('react');
>React : Symbol(React, Decl(file.tsx, 0, 0))

class RC1 extends React.Component<{x : number}, {}> {
>RC1 : Symbol(RC1, Decl(file.tsx, 0, 32))
>React.Component : Symbol(React.Component, Decl(react.d.ts, 158, 55), Decl(react.d.ts, 161, 66))
>React : Symbol(React, Decl(file.tsx, 0, 0))
>Component : Symbol(React.Component, Decl(react.d.ts, 158, 55), Decl(react.d.ts, 161, 66))
>x : Symbol(x, Decl(file.tsx, 2, 35))

    render() {
>render : Symbol(RC1.render, Decl(file.tsx, 2, 53))

        return null;
    }
}

class RC2 extends React.Component<{ x: string }, {}> {
>RC2 : Symbol(RC2, Decl(file.tsx, 6, 1))
>React.Component : Symbol(React.Component, Decl(react.d.ts, 158, 55), Decl(react.d.ts, 161, 66))
>React : Symbol(React, Decl(file.tsx, 0, 0))
>Component : Symbol(React.Component, Decl(react.d.ts, 158, 55), Decl(react.d.ts, 161, 66))
>x : Symbol(x, Decl(file.tsx, 8, 35))

    render() {
>render : Symbol(RC2.render, Decl(file.tsx, 8, 54))

        return null;
    }
    private method() { }
>method : Symbol(RC2.method, Decl(file.tsx, 11, 5))
}

class RC3 extends React.Component<{}, {}> {
>RC3 : Symbol(RC3, Decl(file.tsx, 13, 1))
>React.Component : Symbol(React.Component, Decl(react.d.ts, 158, 55), Decl(react.d.ts, 161, 66))
>React : Symbol(React, Decl(file.tsx, 0, 0))
>Component : Symbol(React.Component, Decl(react.d.ts, 158, 55), Decl(react.d.ts, 161, 66))

    render() {
>render : Symbol(RC3.render, Decl(file.tsx, 15, 43))

        return null;
    }
}

class RC4 extends React.Component<{}, {}> {
>RC4 : Symbol(RC4, Decl(file.tsx, 19, 1))
>React.Component : Symbol(React.Component, Decl(react.d.ts, 158, 55), Decl(react.d.ts, 161, 66))
>React : Symbol(React, Decl(file.tsx, 0, 0))
>Component : Symbol(React.Component, Decl(react.d.ts, 158, 55), Decl(react.d.ts, 161, 66))

    render() {
>render : Symbol(RC4.render, Decl(file.tsx, 21, 43))

        return null;
    }
}

var RCComp = RC1 || RC2;
>RCComp : Symbol(RCComp, Decl(file.tsx, 27, 3))
>RC1 : Symbol(RC1, Decl(file.tsx, 0, 32))
>RC2 : Symbol(RC2, Decl(file.tsx, 6, 1))

var EmptyRCComp = RC3 || RC4;
>EmptyRCComp : Symbol(EmptyRCComp, Decl(file.tsx, 28, 3))
>RC3 : Symbol(RC3, Decl(file.tsx, 13, 1))
>RC4 : Symbol(RC4, Decl(file.tsx, 19, 1))

var PartRCComp = RC1 || RC4;
>PartRCComp : Symbol(PartRCComp, Decl(file.tsx, 29, 3))
>RC1 : Symbol(RC1, Decl(file.tsx, 0, 32))
>RC4 : Symbol(RC4, Decl(file.tsx, 19, 1))

// Error
let a = <RCComp x />;
>a : Symbol(a, Decl(file.tsx, 31, 3))
>RCComp : Symbol(RCComp, Decl(file.tsx, 27, 3))
>x : Symbol(x, Decl(file.tsx, 31, 15))

let b = <PartRCComp x={10} />
>b : Symbol(b, Decl(file.tsx, 32, 3))
>PartRCComp : Symbol(PartRCComp, Decl(file.tsx, 29, 3))
>x : Symbol(x, Decl(file.tsx, 32, 19))

let c = <EmptyRCComp prop />;
>c : Symbol(c, Decl(file.tsx, 33, 3))
>EmptyRCComp : Symbol(EmptyRCComp, Decl(file.tsx, 28, 3))
>prop : Symbol(prop, Decl(file.tsx, 33, 20))