22interface X {
33>X : Symbol(X, Decl(callWithSpread.ts, 0, 0))
44
5- foo(x: number, y: number, ...z: string[]);
5+ foo(x: number, y: number, ...z: string[]): X ;
66>foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
77>x : Symbol(x, Decl(callWithSpread.ts, 1, 8))
88>y : Symbol(y, Decl(callWithSpread.ts, 1, 18))
99>z : Symbol(z, Decl(callWithSpread.ts, 1, 29))
10+ >X : Symbol(X, Decl(callWithSpread.ts, 0, 0))
1011}
1112
1213function foo(x: number, y: number, ...z: string[]) {
@@ -58,6 +59,32 @@ obj.foo(1, 2, ...a, "abc");
5859>foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
5960>a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
6061
62+ obj.foo(1, 2, ...a).foo(1, 2, "abc");
63+ >obj.foo(1, 2, ...a).foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
64+ >obj.foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
65+ >obj : Symbol(obj, Decl(callWithSpread.ts, 9, 3))
66+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
67+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
68+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
69+
70+ obj.foo(1, 2, ...a).foo(1, 2, ...a);
71+ >obj.foo(1, 2, ...a).foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
72+ >obj.foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
73+ >obj : Symbol(obj, Decl(callWithSpread.ts, 9, 3))
74+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
75+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
76+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
77+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
78+
79+ obj.foo(1, 2, ...a).foo(1, 2, ...a, "abc");
80+ >obj.foo(1, 2, ...a).foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
81+ >obj.foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
82+ >obj : Symbol(obj, Decl(callWithSpread.ts, 9, 3))
83+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
84+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
85+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
86+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
87+
6188(obj.foo)(1, 2, "abc");
6289>obj.foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
6390>obj : Symbol(obj, Decl(callWithSpread.ts, 9, 3))
@@ -75,6 +102,32 @@ obj.foo(1, 2, ...a, "abc");
75102>foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
76103>a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
77104
105+ ((obj.foo)(1, 2, ...a).foo)(1, 2, "abc");
106+ >(obj.foo)(1, 2, ...a).foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
107+ >obj.foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
108+ >obj : Symbol(obj, Decl(callWithSpread.ts, 9, 3))
109+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
110+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
111+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
112+
113+ ((obj.foo)(1, 2, ...a).foo)(1, 2, ...a);
114+ >(obj.foo)(1, 2, ...a).foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
115+ >obj.foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
116+ >obj : Symbol(obj, Decl(callWithSpread.ts, 9, 3))
117+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
118+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
119+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
120+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
121+
122+ ((obj.foo)(1, 2, ...a).foo)(1, 2, ...a, "abc");
123+ >(obj.foo)(1, 2, ...a).foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
124+ >obj.foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
125+ >obj : Symbol(obj, Decl(callWithSpread.ts, 9, 3))
126+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
127+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
128+ >foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
129+ >a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
130+
78131xa[1].foo(1, 2, "abc");
79132>xa[1].foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
80133>xa : Symbol(xa, Decl(callWithSpread.ts, 10, 3))
@@ -99,60 +152,60 @@ xa[1].foo(1, 2, ...a, "abc");
99152>foo : Symbol(X.foo, Decl(callWithSpread.ts, 0, 13))
100153
101154class C {
102- >C : Symbol(C, Decl(callWithSpread.ts, 28 , 40))
155+ >C : Symbol(C, Decl(callWithSpread.ts, 36 , 40))
103156
104157 constructor(x: number, y: number, ...z: string[]) {
105- >x : Symbol(x, Decl(callWithSpread.ts, 31 , 16))
106- >y : Symbol(y, Decl(callWithSpread.ts, 31 , 26))
107- >z : Symbol(z, Decl(callWithSpread.ts, 31 , 37))
158+ >x : Symbol(x, Decl(callWithSpread.ts, 39 , 16))
159+ >y : Symbol(y, Decl(callWithSpread.ts, 39 , 26))
160+ >z : Symbol(z, Decl(callWithSpread.ts, 39 , 37))
108161
109162 this.foo(x, y);
110- >this.foo : Symbol(C.foo, Decl(callWithSpread.ts, 34 , 5))
111- >this : Symbol(C, Decl(callWithSpread.ts, 28 , 40))
112- >foo : Symbol(C.foo, Decl(callWithSpread.ts, 34 , 5))
113- >x : Symbol(x, Decl(callWithSpread.ts, 31 , 16))
114- >y : Symbol(y, Decl(callWithSpread.ts, 31 , 26))
163+ >this.foo : Symbol(C.foo, Decl(callWithSpread.ts, 42 , 5))
164+ >this : Symbol(C, Decl(callWithSpread.ts, 36 , 40))
165+ >foo : Symbol(C.foo, Decl(callWithSpread.ts, 42 , 5))
166+ >x : Symbol(x, Decl(callWithSpread.ts, 39 , 16))
167+ >y : Symbol(y, Decl(callWithSpread.ts, 39 , 26))
115168
116169 this.foo(x, y, ...z);
117- >this.foo : Symbol(C.foo, Decl(callWithSpread.ts, 34 , 5))
118- >this : Symbol(C, Decl(callWithSpread.ts, 28 , 40))
119- >foo : Symbol(C.foo, Decl(callWithSpread.ts, 34 , 5))
120- >x : Symbol(x, Decl(callWithSpread.ts, 31 , 16))
121- >y : Symbol(y, Decl(callWithSpread.ts, 31 , 26))
122- >z : Symbol(z, Decl(callWithSpread.ts, 31 , 37))
170+ >this.foo : Symbol(C.foo, Decl(callWithSpread.ts, 42 , 5))
171+ >this : Symbol(C, Decl(callWithSpread.ts, 36 , 40))
172+ >foo : Symbol(C.foo, Decl(callWithSpread.ts, 42 , 5))
173+ >x : Symbol(x, Decl(callWithSpread.ts, 39 , 16))
174+ >y : Symbol(y, Decl(callWithSpread.ts, 39 , 26))
175+ >z : Symbol(z, Decl(callWithSpread.ts, 39 , 37))
123176 }
124177 foo(x: number, y: number, ...z: string[]) {
125- >foo : Symbol(C.foo, Decl(callWithSpread.ts, 34 , 5))
126- >x : Symbol(x, Decl(callWithSpread.ts, 35 , 8))
127- >y : Symbol(y, Decl(callWithSpread.ts, 35 , 18))
128- >z : Symbol(z, Decl(callWithSpread.ts, 35 , 29))
178+ >foo : Symbol(C.foo, Decl(callWithSpread.ts, 42 , 5))
179+ >x : Symbol(x, Decl(callWithSpread.ts, 43 , 8))
180+ >y : Symbol(y, Decl(callWithSpread.ts, 43 , 18))
181+ >z : Symbol(z, Decl(callWithSpread.ts, 43 , 29))
129182 }
130183}
131184
132185class D extends C {
133- >D : Symbol(D, Decl(callWithSpread.ts, 37 , 1))
134- >C : Symbol(C, Decl(callWithSpread.ts, 28 , 40))
186+ >D : Symbol(D, Decl(callWithSpread.ts, 45 , 1))
187+ >C : Symbol(C, Decl(callWithSpread.ts, 36 , 40))
135188
136189 constructor() {
137190 super(1, 2);
138- >super : Symbol(C, Decl(callWithSpread.ts, 28 , 40))
191+ >super : Symbol(C, Decl(callWithSpread.ts, 36 , 40))
139192
140193 super(1, 2, ...a);
141- >super : Symbol(C, Decl(callWithSpread.ts, 28 , 40))
194+ >super : Symbol(C, Decl(callWithSpread.ts, 36 , 40))
142195>a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
143196 }
144197 foo() {
145- >foo : Symbol(D.foo, Decl(callWithSpread.ts, 43 , 5))
198+ >foo : Symbol(D.foo, Decl(callWithSpread.ts, 51 , 5))
146199
147200 super.foo(1, 2);
148- >super.foo : Symbol(C.foo, Decl(callWithSpread.ts, 34 , 5))
149- >super : Symbol(C, Decl(callWithSpread.ts, 28 , 40))
150- >foo : Symbol(C.foo, Decl(callWithSpread.ts, 34 , 5))
201+ >super.foo : Symbol(C.foo, Decl(callWithSpread.ts, 42 , 5))
202+ >super : Symbol(C, Decl(callWithSpread.ts, 36 , 40))
203+ >foo : Symbol(C.foo, Decl(callWithSpread.ts, 42 , 5))
151204
152205 super.foo(1, 2, ...a);
153- >super.foo : Symbol(C.foo, Decl(callWithSpread.ts, 34 , 5))
154- >super : Symbol(C, Decl(callWithSpread.ts, 28 , 40))
155- >foo : Symbol(C.foo, Decl(callWithSpread.ts, 34 , 5))
206+ >super.foo : Symbol(C.foo, Decl(callWithSpread.ts, 42 , 5))
207+ >super : Symbol(C, Decl(callWithSpread.ts, 36 , 40))
208+ >foo : Symbol(C.foo, Decl(callWithSpread.ts, 42 , 5))
156209>a : Symbol(a, Decl(callWithSpread.ts, 7, 3))
157210 }
158211}
0 commit comments