Commit 6a3c9ea
authored
Exhaustive case completion for switch statements (#50996)
* fix services' type's isLiteral
* update literal completions tests
* initial prototype
* use symbol to expression. TODO: filter existing, replace import nodes
* WIP
* WIP
* remove booleans from literals
* trigger at case keyword positions
* clean up tests
* fix element access expression case
* refactor dealing with existing values into a tracker
* fix merge errors
* cleanup and more tests
* fix lint errors
* more merge conflict fixes and cleanup
* use appropriate quotes
* small indentation fix
* refactor case clause tracker
* experiment: support tabstops after each case clause
* address small CR comments
* fix completion entry details; add test case
* fix lint errors
* remove space before tab stops; refactor1 parent 5435efb commit 6a3c9ea
File tree
10 files changed
+925
-42
lines changed- src
- compiler
- services
- tests/cases/fourslash
10 files changed
+925
-42
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
| 55 | + | |
55 | 56 | | |
56 | 57 | | |
57 | 58 | | |
| |||
102 | 103 | | |
103 | 104 | | |
104 | 105 | | |
105 | | - | |
106 | 106 | | |
107 | 107 | | |
108 | 108 | | |
| |||
500 | 500 | | |
501 | 501 | | |
502 | 502 | | |
503 | | - | |
504 | 503 | | |
505 | 504 | | |
506 | 505 | | |
| |||
678 | 677 | | |
679 | 678 | | |
680 | 679 | | |
| 680 | + | |
681 | 681 | | |
682 | 682 | | |
683 | 683 | | |
| |||
827 | 827 | | |
828 | 828 | | |
829 | 829 | | |
| 830 | + | |
830 | 831 | | |
831 | 832 | | |
832 | 833 | | |
| |||
7691 | 7692 | | |
7692 | 7693 | | |
7693 | 7694 | | |
7694 | | - | |
7695 | | - | |
7696 | | - | |
7697 | | - | |
| 7695 | + | |
7698 | 7696 | | |
7699 | 7697 | | |
7700 | 7698 | | |
| |||
23533 | 23531 | | |
23534 | 23532 | | |
23535 | 23533 | | |
23536 | | - | |
23537 | | - | |
23538 | | - | |
23539 | | - | |
23540 | | - | |
23541 | | - | |
23542 | | - | |
23543 | | - | |
23544 | | - | |
23545 | | - | |
23546 | | - | |
23547 | | - | |
23548 | | - | |
23549 | | - | |
23550 | | - | |
23551 | | - | |
23552 | | - | |
23553 | | - | |
23554 | | - | |
23555 | | - | |
23556 | | - | |
23557 | | - | |
23558 | | - | |
23559 | | - | |
23560 | | - | |
23561 | | - | |
23562 | | - | |
23563 | | - | |
23564 | | - | |
| 23534 | + | |
23565 | 23535 | | |
23566 | 23536 | | |
23567 | 23537 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
187 | 187 | | |
188 | 188 | | |
189 | 189 | | |
| 190 | + | |
190 | 191 | | |
191 | 192 | | |
192 | 193 | | |
193 | 194 | | |
194 | 195 | | |
195 | | - | |
196 | 196 | | |
| 197 | + | |
197 | 198 | | |
198 | 199 | | |
199 | 200 | | |
| |||
257 | 258 | | |
258 | 259 | | |
259 | 260 | | |
| 261 | + | |
260 | 262 | | |
261 | 263 | | |
262 | 264 | | |
| |||
440 | 442 | | |
441 | 443 | | |
442 | 444 | | |
| 445 | + | |
443 | 446 | | |
444 | 447 | | |
445 | 448 | | |
| |||
8555 | 8558 | | |
8556 | 8559 | | |
8557 | 8560 | | |
| 8561 | + | |
| 8562 | + | |
| 8563 | + | |
| 8564 | + | |
| 8565 | + | |
| 8566 | + | |
| 8567 | + | |
| 8568 | + | |
| 8569 | + | |
| 8570 | + | |
| 8571 | + | |
| 8572 | + | |
| 8573 | + | |
| 8574 | + | |
| 8575 | + | |
| 8576 | + | |
| 8577 | + | |
| 8578 | + | |
| 8579 | + | |
| 8580 | + | |
| 8581 | + | |
| 8582 | + | |
| 8583 | + | |
| 8584 | + | |
| 8585 | + | |
| 8586 | + | |
| 8587 | + | |
| 8588 | + | |
| 8589 | + | |
| 8590 | + | |
| 8591 | + | |
| 8592 | + | |
| 8593 | + | |
| 8594 | + | |
| 8595 | + | |
| 8596 | + | |
| 8597 | + | |
| 8598 | + | |
| 8599 | + | |
| 8600 | + | |
| 8601 | + | |
| 8602 | + | |
| 8603 | + | |
| 8604 | + | |
| 8605 | + | |
8558 | 8606 | | |
8559 | 8607 | | |
8560 | 8608 | | |
| |||
9062 | 9110 | | |
9063 | 9111 | | |
9064 | 9112 | | |
| 9113 | + | |
| 9114 | + | |
| 9115 | + | |
| 9116 | + | |
| 9117 | + | |
| 9118 | + | |
| 9119 | + | |
| 9120 | + | |
| 9121 | + | |
| 9122 | + | |
| 9123 | + | |
| 9124 | + | |
| 9125 | + | |
| 9126 | + | |
| 9127 | + | |
| 9128 | + | |
| 9129 | + | |
9065 | 9130 | | |
0 commit comments