File: typesWithSpecializedConstructSignatures.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 (106 lines) | stat: -rw-r--r-- 4,493 bytes parent folder | download | duplicates (7)
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
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
=== tests/cases/conformance/types/members/typesWithSpecializedConstructSignatures.ts ===
// basic uses of specialized signatures without errors

class Base { foo: string }
>Base : Symbol(Base, Decl(typesWithSpecializedConstructSignatures.ts, 0, 0))
>foo : Symbol(Base.foo, Decl(typesWithSpecializedConstructSignatures.ts, 2, 12))

class Derived1 extends Base { bar: string }
>Derived1 : Symbol(Derived1, Decl(typesWithSpecializedConstructSignatures.ts, 2, 26))
>Base : Symbol(Base, Decl(typesWithSpecializedConstructSignatures.ts, 0, 0))
>bar : Symbol(Derived1.bar, Decl(typesWithSpecializedConstructSignatures.ts, 3, 29))

class Derived2 extends Base { baz: string }
>Derived2 : Symbol(Derived2, Decl(typesWithSpecializedConstructSignatures.ts, 3, 43))
>Base : Symbol(Base, Decl(typesWithSpecializedConstructSignatures.ts, 0, 0))
>baz : Symbol(Derived2.baz, Decl(typesWithSpecializedConstructSignatures.ts, 4, 29))

class C {
>C : Symbol(C, Decl(typesWithSpecializedConstructSignatures.ts, 4, 43))

    constructor(x: 'hi');
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 7, 16))

    constructor(x: 'bye');
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 8, 16))

    constructor(x: string);
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 9, 16))

    constructor(x) {
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 10, 16))

        return x;
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 10, 16))
    }
}
var c = new C('a');
>c : Symbol(c, Decl(typesWithSpecializedConstructSignatures.ts, 14, 3))
>C : Symbol(C, Decl(typesWithSpecializedConstructSignatures.ts, 4, 43))

interface I {
>I : Symbol(I, Decl(typesWithSpecializedConstructSignatures.ts, 14, 19))

    new(x: 'hi'): Derived1;
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 17, 8))
>Derived1 : Symbol(Derived1, Decl(typesWithSpecializedConstructSignatures.ts, 2, 26))

    new(x: 'bye'): Derived2;
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 18, 8))
>Derived2 : Symbol(Derived2, Decl(typesWithSpecializedConstructSignatures.ts, 3, 43))

    new(x: string): Base;
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 19, 8))
>Base : Symbol(Base, Decl(typesWithSpecializedConstructSignatures.ts, 0, 0))
}
var i: I;
>i : Symbol(i, Decl(typesWithSpecializedConstructSignatures.ts, 21, 3))
>I : Symbol(I, Decl(typesWithSpecializedConstructSignatures.ts, 14, 19))

var a: {
>a : Symbol(a, Decl(typesWithSpecializedConstructSignatures.ts, 23, 3))

    new(x: 'hi'): Derived1;
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 24, 8))
>Derived1 : Symbol(Derived1, Decl(typesWithSpecializedConstructSignatures.ts, 2, 26))

    new(x: 'bye'): Derived2;
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 25, 8))
>Derived2 : Symbol(Derived2, Decl(typesWithSpecializedConstructSignatures.ts, 3, 43))

    new(x: string): Base;
>x : Symbol(x, Decl(typesWithSpecializedConstructSignatures.ts, 26, 8))
>Base : Symbol(Base, Decl(typesWithSpecializedConstructSignatures.ts, 0, 0))

};

c = i;
>c : Symbol(c, Decl(typesWithSpecializedConstructSignatures.ts, 14, 3))
>i : Symbol(i, Decl(typesWithSpecializedConstructSignatures.ts, 21, 3))

c = a;
>c : Symbol(c, Decl(typesWithSpecializedConstructSignatures.ts, 14, 3))
>a : Symbol(a, Decl(typesWithSpecializedConstructSignatures.ts, 23, 3))

i = a;
>i : Symbol(i, Decl(typesWithSpecializedConstructSignatures.ts, 21, 3))
>a : Symbol(a, Decl(typesWithSpecializedConstructSignatures.ts, 23, 3))

a = i;
>a : Symbol(a, Decl(typesWithSpecializedConstructSignatures.ts, 23, 3))
>i : Symbol(i, Decl(typesWithSpecializedConstructSignatures.ts, 21, 3))

var r1 = new C('hi');
>r1 : Symbol(r1, Decl(typesWithSpecializedConstructSignatures.ts, 36, 3))
>C : Symbol(C, Decl(typesWithSpecializedConstructSignatures.ts, 4, 43))

var r2: Derived2 = new i('bye');
>r2 : Symbol(r2, Decl(typesWithSpecializedConstructSignatures.ts, 37, 3))
>Derived2 : Symbol(Derived2, Decl(typesWithSpecializedConstructSignatures.ts, 3, 43))
>i : Symbol(i, Decl(typesWithSpecializedConstructSignatures.ts, 21, 3))

var r3: Base = new a('hm');
>r3 : Symbol(r3, Decl(typesWithSpecializedConstructSignatures.ts, 38, 3))
>Base : Symbol(Base, Decl(typesWithSpecializedConstructSignatures.ts, 0, 0))
>a : Symbol(a, Decl(typesWithSpecializedConstructSignatures.ts, 23, 3))