@@ -3,27 +3,45 @@ interface I<T> {
3
3
>I : Symbol(I, Decl(computedPropertyNamesContextualType7_ES5.ts, 0, 0))
4
4
>T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 0, 12))
5
5
6
- [s : number]: T;
7
- >s : Symbol(s , Decl(computedPropertyNamesContextualType7_ES5.ts, 1, 5))
6
+ [n : number]: T;
7
+ >n : Symbol(n , Decl(computedPropertyNamesContextualType7_ES5.ts, 1, 5))
8
8
>T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 0, 12))
9
9
}
10
+ interface J<T> {
11
+ >J : Symbol(J, Decl(computedPropertyNamesContextualType7_ES5.ts, 2, 1))
12
+ >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 3, 12))
10
13
11
- declare function foo<T>(obj: I<T>): T
12
- >foo : Symbol(foo, Decl(computedPropertyNamesContextualType7_ES5.ts, 2, 1))
13
- >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 4, 21))
14
- >obj : Symbol(obj, Decl(computedPropertyNamesContextualType7_ES5.ts, 4, 24))
14
+ [s: string]: T;
15
+ >s : Symbol(s, Decl(computedPropertyNamesContextualType7_ES5.ts, 4, 5))
16
+ >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 3, 12))
17
+ }
18
+
19
+ declare function foo<T>(obj: I<T>): T;
20
+ >foo : Symbol(foo, Decl(computedPropertyNamesContextualType7_ES5.ts, 5, 1))
21
+ >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 7, 21))
22
+ >obj : Symbol(obj, Decl(computedPropertyNamesContextualType7_ES5.ts, 7, 24))
15
23
>I : Symbol(I, Decl(computedPropertyNamesContextualType7_ES5.ts, 0, 0))
16
- >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 4 , 21))
17
- >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 4 , 21))
24
+ >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 7 , 21))
25
+ >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 7 , 21))
18
26
19
- foo({
20
- >foo : Symbol(foo, Decl(computedPropertyNamesContextualType7_ES5.ts, 2, 1))
27
+ declare function g<T>(obj: J<T>): T;
28
+ >g : Symbol(g, Decl(computedPropertyNamesContextualType7_ES5.ts, 7, 38))
29
+ >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 8, 19))
30
+ >obj : Symbol(obj, Decl(computedPropertyNamesContextualType7_ES5.ts, 8, 22))
31
+ >J : Symbol(J, Decl(computedPropertyNamesContextualType7_ES5.ts, 2, 1))
32
+ >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 8, 19))
33
+ >T : Symbol(T, Decl(computedPropertyNamesContextualType7_ES5.ts, 8, 19))
21
34
22
- p: "",
23
- >p : Symbol(p , Decl(computedPropertyNamesContextualType7_ES5.ts, 6, 5 ))
35
+ foo({
36
+ >foo : Symbol(foo , Decl(computedPropertyNamesContextualType7_ES5.ts, 5, 1 ))
24
37
25
38
0: () => { },
26
39
["hi" + "bye"]: true,
27
40
[0 + 1]: 0,
28
41
[+"hi"]: [0]
29
42
});
43
+
44
+ g({ p: "" });
45
+ >g : Symbol(g, Decl(computedPropertyNamesContextualType7_ES5.ts, 7, 38))
46
+ >p : Symbol(p, Decl(computedPropertyNamesContextualType7_ES5.ts, 17, 3))
47
+
0 commit comments