File: multipleInheritance.symbols

package info (click to toggle)
node-typescript 3.3.3333-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 324,548 kB
  • sloc: makefile: 6; sh: 3
file content (74 lines) | stat: -rw-r--r-- 2,118 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
=== tests/cases/compiler/multipleInheritance.ts ===
class B1 {
>B1 : Symbol(B1, Decl(multipleInheritance.ts, 0, 0))

    public x;
>x : Symbol(B1.x, Decl(multipleInheritance.ts, 0, 10))
}

class B2 {
>B2 : Symbol(B2, Decl(multipleInheritance.ts, 2, 1))

    public x;
>x : Symbol(B2.x, Decl(multipleInheritance.ts, 4, 10))
}

class C extends B1, B2 { // duplicate member
>C : Symbol(C, Decl(multipleInheritance.ts, 6, 1))
>B1 : Symbol(B1, Decl(multipleInheritance.ts, 0, 0))
>B2 : Symbol(B2, Decl(multipleInheritance.ts, 2, 1))
}

class D1 extends B1 {
>D1 : Symbol(D1, Decl(multipleInheritance.ts, 9, 1))
>B1 : Symbol(B1, Decl(multipleInheritance.ts, 0, 0))
}

class D2 extends B2 {
>D2 : Symbol(D2, Decl(multipleInheritance.ts, 12, 1))
>B2 : Symbol(B2, Decl(multipleInheritance.ts, 2, 1))
}

class E extends D1, D2 { // nope, duplicate member
>E : Symbol(E, Decl(multipleInheritance.ts, 15, 1))
>D1 : Symbol(D1, Decl(multipleInheritance.ts, 9, 1))
>D2 : Symbol(D2, Decl(multipleInheritance.ts, 12, 1))
}

class N {
>N : Symbol(N, Decl(multipleInheritance.ts, 18, 1))

    public y:number;
>y : Symbol(N.y, Decl(multipleInheritance.ts, 20, 9))
}

class ND extends N { // any is assignable to number
>ND : Symbol(ND, Decl(multipleInheritance.ts, 22, 1))
>N : Symbol(N, Decl(multipleInheritance.ts, 18, 1))

    public y;
>y : Symbol(ND.y, Decl(multipleInheritance.ts, 24, 20))
}

class Good {
>Good : Symbol(Good, Decl(multipleInheritance.ts, 26, 1))

    public f:() => number = function() { return 0; }
>f : Symbol(Good.f, Decl(multipleInheritance.ts, 28, 12))

    public g() { return 0; }
>g : Symbol(Good.g, Decl(multipleInheritance.ts, 29, 52))
}

class Baad extends Good {
>Baad : Symbol(Baad, Decl(multipleInheritance.ts, 31, 1))
>Good : Symbol(Good, Decl(multipleInheritance.ts, 26, 1))

    public f(): number { return 0; }
>f : Symbol(Baad.f, Decl(multipleInheritance.ts, 33, 25))

    public g(n:number) { return 0; }
>g : Symbol(Baad.g, Decl(multipleInheritance.ts, 34, 36))
>n : Symbol(n, Decl(multipleInheritance.ts, 35, 13))
}