File: typeInferenceWithExcessProperties.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 (65 lines) | stat: -rw-r--r-- 1,933 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
=== tests/cases/compiler/typeInferenceWithExcessProperties.ts ===
// Repro from #17041

interface Named {
>Named : Symbol(Named, Decl(typeInferenceWithExcessProperties.ts, 0, 0))

    name: string;
>name : Symbol(Named.name, Decl(typeInferenceWithExcessProperties.ts, 2, 17))
}

function parrot<T extends Named>(obj: T): T {
>parrot : Symbol(parrot, Decl(typeInferenceWithExcessProperties.ts, 4, 1))
>T : Symbol(T, Decl(typeInferenceWithExcessProperties.ts, 6, 16))
>Named : Symbol(Named, Decl(typeInferenceWithExcessProperties.ts, 0, 0))
>obj : Symbol(obj, Decl(typeInferenceWithExcessProperties.ts, 6, 33))
>T : Symbol(T, Decl(typeInferenceWithExcessProperties.ts, 6, 16))
>T : Symbol(T, Decl(typeInferenceWithExcessProperties.ts, 6, 16))

    return obj;
>obj : Symbol(obj, Decl(typeInferenceWithExcessProperties.ts, 6, 33))
}


parrot({
>parrot : Symbol(parrot, Decl(typeInferenceWithExcessProperties.ts, 4, 1))

    name: "TypeScript",
>name : Symbol(name, Decl(typeInferenceWithExcessProperties.ts, 11, 8))

});

parrot({
>parrot : Symbol(parrot, Decl(typeInferenceWithExcessProperties.ts, 4, 1))

    name: "TypeScript",
>name : Symbol(name, Decl(typeInferenceWithExcessProperties.ts, 15, 8))

    age: 5,
>age : Symbol(age, Decl(typeInferenceWithExcessProperties.ts, 16, 23))

});

parrot({
>parrot : Symbol(parrot, Decl(typeInferenceWithExcessProperties.ts, 4, 1))

    name: "TypeScript",
>name : Symbol(name, Decl(typeInferenceWithExcessProperties.ts, 20, 8))

    age: function () { },
>age : Symbol(age, Decl(typeInferenceWithExcessProperties.ts, 21, 23))

});

parrot({
>parrot : Symbol(parrot, Decl(typeInferenceWithExcessProperties.ts, 4, 1))

    name: "TypeScript",
>name : Symbol(name, Decl(typeInferenceWithExcessProperties.ts, 25, 8))

    sayHello() {
>sayHello : Symbol(sayHello, Decl(typeInferenceWithExcessProperties.ts, 26, 23))

    },
});