File: hidingCallSignatures.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 (55 lines) | stat: -rw-r--r-- 1,481 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
=== tests/cases/compiler/hidingCallSignatures.ts ===
interface C {
>C : Symbol(C, Decl(hidingCallSignatures.ts, 0, 0))

    new (a: string): string;
>a : Symbol(a, Decl(hidingCallSignatures.ts, 1, 9))
}

interface D extends C {
>D : Symbol(D, Decl(hidingCallSignatures.ts, 2, 1))
>C : Symbol(C, Decl(hidingCallSignatures.ts, 0, 0))

    (a: string): number; // Should be ok
>a : Symbol(a, Decl(hidingCallSignatures.ts, 5, 5))
}

interface E {
>E : Symbol(E, Decl(hidingCallSignatures.ts, 6, 1))

    (a: string): {};
>a : Symbol(a, Decl(hidingCallSignatures.ts, 9, 5))
}

interface F extends E {
>F : Symbol(F, Decl(hidingCallSignatures.ts, 10, 1))
>E : Symbol(E, Decl(hidingCallSignatures.ts, 6, 1))

    (a: string): string;
>a : Symbol(a, Decl(hidingCallSignatures.ts, 13, 5))
}

var d: D;
>d : Symbol(d, Decl(hidingCallSignatures.ts, 16, 3))
>D : Symbol(D, Decl(hidingCallSignatures.ts, 2, 1))

d(""); // number
>d : Symbol(d, Decl(hidingCallSignatures.ts, 16, 3))

new d(""); // should be string
>d : Symbol(d, Decl(hidingCallSignatures.ts, 16, 3))

var f: F;
>f : Symbol(f, Decl(hidingCallSignatures.ts, 20, 3))
>F : Symbol(F, Decl(hidingCallSignatures.ts, 10, 1))

f(""); // string
>f : Symbol(f, Decl(hidingCallSignatures.ts, 20, 3))

var e: E;
>e : Symbol(e, Decl(hidingCallSignatures.ts, 23, 3))
>E : Symbol(E, Decl(hidingCallSignatures.ts, 6, 1))

e(""); // {}
>e : Symbol(e, Decl(hidingCallSignatures.ts, 23, 3))