@@ -280,130 +280,157 @@ function f30({ kind, isA }: Foo) {
280
280
}
281
281
}
282
282
283
+ type Args = ['A', number] | ['B', string]
284
+ >Args : Symbol(Args, Decl(dependentDestructuredVariables.ts, 111, 1))
285
+
286
+ function f40(...[kind, data]: Args) {
287
+ >f40 : Symbol(f40, Decl(dependentDestructuredVariables.ts, 113, 41))
288
+ >kind : Symbol(kind, Decl(dependentDestructuredVariables.ts, 115, 17))
289
+ >data : Symbol(data, Decl(dependentDestructuredVariables.ts, 115, 22))
290
+ >Args : Symbol(Args, Decl(dependentDestructuredVariables.ts, 111, 1))
291
+
292
+ if (kind === 'A') {
293
+ >kind : Symbol(kind, Decl(dependentDestructuredVariables.ts, 115, 17))
294
+
295
+ data.toFixed();
296
+ >data.toFixed : Symbol(Number.toFixed, Decl(lib.es5.d.ts, --, --))
297
+ >data : Symbol(data, Decl(dependentDestructuredVariables.ts, 115, 22))
298
+ >toFixed : Symbol(Number.toFixed, Decl(lib.es5.d.ts, --, --))
299
+ }
300
+ if (kind === 'B') {
301
+ >kind : Symbol(kind, Decl(dependentDestructuredVariables.ts, 115, 17))
302
+
303
+ data.toUpperCase();
304
+ >data.toUpperCase : Symbol(String.toUpperCase, Decl(lib.es5.d.ts, --, --))
305
+ >data : Symbol(data, Decl(dependentDestructuredVariables.ts, 115, 22))
306
+ >toUpperCase : Symbol(String.toUpperCase, Decl(lib.es5.d.ts, --, --))
307
+ }
308
+ }
309
+
283
310
// Repro from #35283
284
311
285
312
interface A<T> { variant: 'a', value: T }
286
- >A : Symbol(A, Decl(dependentDestructuredVariables.ts, 111 , 1))
287
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 115 , 12))
288
- >variant : Symbol(A.variant, Decl(dependentDestructuredVariables.ts, 115 , 16))
289
- >value : Symbol(A.value, Decl(dependentDestructuredVariables.ts, 115 , 30))
290
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 115 , 12))
313
+ >A : Symbol(A, Decl(dependentDestructuredVariables.ts, 122 , 1))
314
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 126 , 12))
315
+ >variant : Symbol(A.variant, Decl(dependentDestructuredVariables.ts, 126 , 16))
316
+ >value : Symbol(A.value, Decl(dependentDestructuredVariables.ts, 126 , 30))
317
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 126 , 12))
291
318
292
319
interface B<T> { variant: 'b', value: Array<T> }
293
- >B : Symbol(B, Decl(dependentDestructuredVariables.ts, 115 , 41))
294
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 117 , 12))
295
- >variant : Symbol(B.variant, Decl(dependentDestructuredVariables.ts, 117 , 16))
296
- >value : Symbol(B.value, Decl(dependentDestructuredVariables.ts, 117 , 30))
320
+ >B : Symbol(B, Decl(dependentDestructuredVariables.ts, 126 , 41))
321
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 128 , 12))
322
+ >variant : Symbol(B.variant, Decl(dependentDestructuredVariables.ts, 128 , 16))
323
+ >value : Symbol(B.value, Decl(dependentDestructuredVariables.ts, 128 , 30))
297
324
>Array : Symbol(Array, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es2015.core.d.ts, --, --), Decl(lib.es2015.iterable.d.ts, --, --), Decl(lib.es2015.symbol.wellknown.d.ts, --, --))
298
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 117 , 12))
325
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 128 , 12))
299
326
300
327
type AB<T> = A<T> | B<T>;
301
- >AB : Symbol(AB, Decl(dependentDestructuredVariables.ts, 117 , 48))
302
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 119 , 8))
303
- >A : Symbol(A, Decl(dependentDestructuredVariables.ts, 111 , 1))
304
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 119 , 8))
305
- >B : Symbol(B, Decl(dependentDestructuredVariables.ts, 115 , 41))
306
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 119 , 8))
328
+ >AB : Symbol(AB, Decl(dependentDestructuredVariables.ts, 128 , 48))
329
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 130 , 8))
330
+ >A : Symbol(A, Decl(dependentDestructuredVariables.ts, 122 , 1))
331
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 130 , 8))
332
+ >B : Symbol(B, Decl(dependentDestructuredVariables.ts, 126 , 41))
333
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 130 , 8))
307
334
308
335
declare function printValue<T>(t: T): void;
309
- >printValue : Symbol(printValue, Decl(dependentDestructuredVariables.ts, 119 , 25))
310
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 121 , 28))
311
- >t : Symbol(t, Decl(dependentDestructuredVariables.ts, 121 , 31))
312
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 121 , 28))
336
+ >printValue : Symbol(printValue, Decl(dependentDestructuredVariables.ts, 130 , 25))
337
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 132 , 28))
338
+ >t : Symbol(t, Decl(dependentDestructuredVariables.ts, 132 , 31))
339
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 132 , 28))
313
340
314
341
declare function printValueList<T>(t: Array<T>): void;
315
- >printValueList : Symbol(printValueList, Decl(dependentDestructuredVariables.ts, 121 , 43))
316
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 123 , 32))
317
- >t : Symbol(t, Decl(dependentDestructuredVariables.ts, 123 , 35))
342
+ >printValueList : Symbol(printValueList, Decl(dependentDestructuredVariables.ts, 132 , 43))
343
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 134 , 32))
344
+ >t : Symbol(t, Decl(dependentDestructuredVariables.ts, 134 , 35))
318
345
>Array : Symbol(Array, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es2015.core.d.ts, --, --), Decl(lib.es2015.iterable.d.ts, --, --), Decl(lib.es2015.symbol.wellknown.d.ts, --, --))
319
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 123 , 32))
346
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 134 , 32))
320
347
321
348
function unrefined1<T>(ab: AB<T>): void {
322
- >unrefined1 : Symbol(unrefined1, Decl(dependentDestructuredVariables.ts, 123 , 54))
323
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 125 , 20))
324
- >ab : Symbol(ab, Decl(dependentDestructuredVariables.ts, 125 , 23))
325
- >AB : Symbol(AB, Decl(dependentDestructuredVariables.ts, 117 , 48))
326
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 125 , 20))
349
+ >unrefined1 : Symbol(unrefined1, Decl(dependentDestructuredVariables.ts, 134 , 54))
350
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 136 , 20))
351
+ >ab : Symbol(ab, Decl(dependentDestructuredVariables.ts, 136 , 23))
352
+ >AB : Symbol(AB, Decl(dependentDestructuredVariables.ts, 128 , 48))
353
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 136 , 20))
327
354
328
355
const { variant, value } = ab;
329
- >variant : Symbol(variant, Decl(dependentDestructuredVariables.ts, 126 , 11))
330
- >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 126 , 20))
331
- >ab : Symbol(ab, Decl(dependentDestructuredVariables.ts, 125 , 23))
356
+ >variant : Symbol(variant, Decl(dependentDestructuredVariables.ts, 137 , 11))
357
+ >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 137 , 20))
358
+ >ab : Symbol(ab, Decl(dependentDestructuredVariables.ts, 136 , 23))
332
359
333
360
if (variant === 'a') {
334
- >variant : Symbol(variant, Decl(dependentDestructuredVariables.ts, 126 , 11))
361
+ >variant : Symbol(variant, Decl(dependentDestructuredVariables.ts, 137 , 11))
335
362
336
363
printValue<T>(value);
337
- >printValue : Symbol(printValue, Decl(dependentDestructuredVariables.ts, 119 , 25))
338
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 125 , 20))
339
- >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 126 , 20))
364
+ >printValue : Symbol(printValue, Decl(dependentDestructuredVariables.ts, 130 , 25))
365
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 136 , 20))
366
+ >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 137 , 20))
340
367
}
341
368
else {
342
369
printValueList<T>(value);
343
- >printValueList : Symbol(printValueList, Decl(dependentDestructuredVariables.ts, 121 , 43))
344
- >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 125 , 20))
345
- >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 126 , 20))
370
+ >printValueList : Symbol(printValueList, Decl(dependentDestructuredVariables.ts, 132 , 43))
371
+ >T : Symbol(T, Decl(dependentDestructuredVariables.ts, 136 , 20))
372
+ >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 137 , 20))
346
373
}
347
374
}
348
375
349
376
// Repro from #38020
350
377
351
378
type Action3 =
352
- >Action3 : Symbol(Action3, Decl(dependentDestructuredVariables.ts, 133 , 1))
379
+ >Action3 : Symbol(Action3, Decl(dependentDestructuredVariables.ts, 144 , 1))
353
380
354
381
| {type: 'add', payload: { toAdd: number } }
355
- >type : Symbol(type, Decl(dependentDestructuredVariables.ts, 138 , 7))
356
- >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 138 , 19))
357
- >toAdd : Symbol(toAdd, Decl(dependentDestructuredVariables.ts, 138 , 30))
382
+ >type : Symbol(type, Decl(dependentDestructuredVariables.ts, 149 , 7))
383
+ >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 149 , 19))
384
+ >toAdd : Symbol(toAdd, Decl(dependentDestructuredVariables.ts, 149 , 30))
358
385
359
386
| {type: 'remove', payload: { toRemove: number } };
360
- >type : Symbol(type, Decl(dependentDestructuredVariables.ts, 139 , 7))
361
- >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 139 , 22))
362
- >toRemove : Symbol(toRemove, Decl(dependentDestructuredVariables.ts, 139 , 33))
387
+ >type : Symbol(type, Decl(dependentDestructuredVariables.ts, 150 , 7))
388
+ >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 150 , 22))
389
+ >toRemove : Symbol(toRemove, Decl(dependentDestructuredVariables.ts, 150 , 33))
363
390
364
391
const reducerBroken = (state: number, { type, payload }: Action3) => {
365
- >reducerBroken : Symbol(reducerBroken, Decl(dependentDestructuredVariables.ts, 141 , 5))
366
- >state : Symbol(state, Decl(dependentDestructuredVariables.ts, 141 , 23))
367
- >type : Symbol(type, Decl(dependentDestructuredVariables.ts, 141 , 39))
368
- >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 141 , 45))
369
- >Action3 : Symbol(Action3, Decl(dependentDestructuredVariables.ts, 133 , 1))
392
+ >reducerBroken : Symbol(reducerBroken, Decl(dependentDestructuredVariables.ts, 152 , 5))
393
+ >state : Symbol(state, Decl(dependentDestructuredVariables.ts, 152 , 23))
394
+ >type : Symbol(type, Decl(dependentDestructuredVariables.ts, 152 , 39))
395
+ >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 152 , 45))
396
+ >Action3 : Symbol(Action3, Decl(dependentDestructuredVariables.ts, 144 , 1))
370
397
371
398
switch (type) {
372
- >type : Symbol(type, Decl(dependentDestructuredVariables.ts, 141 , 39))
399
+ >type : Symbol(type, Decl(dependentDestructuredVariables.ts, 152 , 39))
373
400
374
401
case 'add':
375
402
return state + payload.toAdd;
376
- >state : Symbol(state, Decl(dependentDestructuredVariables.ts, 141 , 23))
377
- >payload.toAdd : Symbol(toAdd, Decl(dependentDestructuredVariables.ts, 138 , 30))
378
- >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 141 , 45))
379
- >toAdd : Symbol(toAdd, Decl(dependentDestructuredVariables.ts, 138 , 30))
403
+ >state : Symbol(state, Decl(dependentDestructuredVariables.ts, 152 , 23))
404
+ >payload.toAdd : Symbol(toAdd, Decl(dependentDestructuredVariables.ts, 149 , 30))
405
+ >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 152 , 45))
406
+ >toAdd : Symbol(toAdd, Decl(dependentDestructuredVariables.ts, 149 , 30))
380
407
381
408
case 'remove':
382
409
return state - payload.toRemove;
383
- >state : Symbol(state, Decl(dependentDestructuredVariables.ts, 141 , 23))
384
- >payload.toRemove : Symbol(toRemove, Decl(dependentDestructuredVariables.ts, 139 , 33))
385
- >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 141 , 45))
386
- >toRemove : Symbol(toRemove, Decl(dependentDestructuredVariables.ts, 139 , 33))
410
+ >state : Symbol(state, Decl(dependentDestructuredVariables.ts, 152 , 23))
411
+ >payload.toRemove : Symbol(toRemove, Decl(dependentDestructuredVariables.ts, 150 , 33))
412
+ >payload : Symbol(payload, Decl(dependentDestructuredVariables.ts, 152 , 45))
413
+ >toRemove : Symbol(toRemove, Decl(dependentDestructuredVariables.ts, 150 , 33))
387
414
}
388
415
}
389
416
390
417
// Repro from #46143
391
418
392
419
declare var it: Iterator<number>;
393
- >it : Symbol(it, Decl(dependentDestructuredVariables.ts, 152 , 11))
420
+ >it : Symbol(it, Decl(dependentDestructuredVariables.ts, 163 , 11))
394
421
>Iterator : Symbol(Iterator, Decl(lib.es2015.iterable.d.ts, --, --))
395
422
396
423
const { value, done } = it.next();
397
- >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 153 , 7))
398
- >done : Symbol(done, Decl(dependentDestructuredVariables.ts, 153 , 14))
424
+ >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 164 , 7))
425
+ >done : Symbol(done, Decl(dependentDestructuredVariables.ts, 164 , 14))
399
426
>it.next : Symbol(Iterator.next, Decl(lib.es2015.iterable.d.ts, --, --))
400
- >it : Symbol(it, Decl(dependentDestructuredVariables.ts, 152 , 11))
427
+ >it : Symbol(it, Decl(dependentDestructuredVariables.ts, 163 , 11))
401
428
>next : Symbol(Iterator.next, Decl(lib.es2015.iterable.d.ts, --, --))
402
429
403
430
if (!done) {
404
- >done : Symbol(done, Decl(dependentDestructuredVariables.ts, 153 , 14))
431
+ >done : Symbol(done, Decl(dependentDestructuredVariables.ts, 164 , 14))
405
432
406
433
value; // number
407
- >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 153 , 7))
434
+ >value : Symbol(value, Decl(dependentDestructuredVariables.ts, 164 , 7))
408
435
}
409
436
0 commit comments