Commit 7d9b22e
authored
Add semicolon preference to formatter options (microsoft#33402)
* Add UserPreferences for semicolons
* Prototype formatter semicolon removal
* Implement semicolon insertion
* Fix existing tests
* Start adding tests
* Fix some edge cases of semicolon deletion
* Fix semicolon removal before comments
* Fix indentation
* Test on checker
* Replace semicolon-omitting writer with formatter preference
* Fix writing new nodes, update protocol
* Rename option
* Really fix formatting synthetic nodes
* Fix refactoring misses
* Un-update submodules gahhhh
* Update APIs
* Update for ESLint
* Revert accidental test change
* De-kludge deduplication of EOF processing
* Omit last element semicolon from single-line object-like types
* Revert "Omit last element semicolon from single-line object-like types"
This reverts commit 5625cb0.
* Fix straggler test
* Add test for leading semicolon class members
* Rename a lot of stuff for clarity
* Invert some boolean logic1 parent 3dd7b84 commit 7d9b22e
File tree
29 files changed
+817
-257
lines changed- src
- compiler
- harness
- server
- services
- codefixes
- formatting
- tests
- baselines/reference/api
- cases/fourslash
29 files changed
+817
-257
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
329 | 329 | | |
330 | 330 | | |
331 | 331 | | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
332 | 347 | | |
333 | 348 | | |
334 | 349 | | |
| |||
2159 | 2174 | | |
2160 | 2175 | | |
2161 | 2176 | | |
2162 | | - | |
2163 | | - | |
| 2177 | + | |
| 2178 | + | |
| 2179 | + | |
| 2180 | + | |
| 2181 | + | |
| 2182 | + | |
| 2183 | + | |
| 2184 | + | |
| 2185 | + | |
| 2186 | + | |
| 2187 | + | |
| 2188 | + | |
| 2189 | + | |
2164 | 2190 | | |
2165 | 2191 | | |
2166 | 2192 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3380 | 3380 | | |
3381 | 3381 | | |
3382 | 3382 | | |
3383 | | - | |
3384 | | - | |
3385 | | - | |
3386 | | - | |
3387 | | - | |
| 3383 | + | |
3388 | 3384 | | |
3389 | 3385 | | |
3390 | 3386 | | |
| |||
3451 | 3447 | | |
3452 | 3448 | | |
3453 | 3449 | | |
3454 | | - | |
3455 | | - | |
3456 | | - | |
3457 | | - | |
3458 | | - | |
3459 | | - | |
3460 | | - | |
3461 | | - | |
3462 | | - | |
3463 | | - | |
3464 | | - | |
3465 | | - | |
3466 | | - | |
3467 | | - | |
3468 | 3450 | | |
3469 | 3451 | | |
3470 | 3452 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1683 | 1683 | | |
1684 | 1684 | | |
1685 | 1685 | | |
1686 | | - | |
| 1686 | + | |
1687 | 1687 | | |
1688 | 1688 | | |
1689 | 1689 | | |
| |||
1756 | 1756 | | |
1757 | 1757 | | |
1758 | 1758 | | |
1759 | | - | |
| 1759 | + | |
1760 | 1760 | | |
1761 | 1761 | | |
1762 | 1762 | | |
| |||
1775 | 1775 | | |
1776 | 1776 | | |
1777 | 1777 | | |
1778 | | - | |
| 1778 | + | |
1779 | 1779 | | |
1780 | 1780 | | |
1781 | 1781 | | |
| |||
1810 | 1810 | | |
1811 | 1811 | | |
1812 | 1812 | | |
1813 | | - | |
1814 | | - | |
1815 | | - | |
| 1813 | + | |
1816 | 1814 | | |
1817 | 1815 | | |
1818 | 1816 | | |
| |||
1833 | 1831 | | |
1834 | 1832 | | |
1835 | 1833 | | |
1836 | | - | |
1837 | | - | |
1838 | | - | |
1839 | | - | |
1840 | | - | |
1841 | | - | |
1842 | | - | |
1843 | | - | |
1844 | 1834 | | |
1845 | 1835 | | |
1846 | 1836 | | |
| |||
1856 | 1846 | | |
1857 | 1847 | | |
1858 | 1848 | | |
1859 | | - | |
| 1849 | + | |
1860 | 1850 | | |
1861 | 1851 | | |
1862 | 1852 | | |
1863 | 1853 | | |
1864 | | - | |
| 1854 | + | |
1865 | 1855 | | |
1866 | 1856 | | |
1867 | 1857 | | |
1868 | 1858 | | |
1869 | | - | |
| 1859 | + | |
1870 | 1860 | | |
1871 | 1861 | | |
1872 | 1862 | | |
| |||
2414 | 2404 | | |
2415 | 2405 | | |
2416 | 2406 | | |
2417 | | - | |
| 2407 | + | |
2418 | 2408 | | |
2419 | 2409 | | |
2420 | 2410 | | |
| |||
2497 | 2487 | | |
2498 | 2488 | | |
2499 | 2489 | | |
2500 | | - | |
| 2490 | + | |
2501 | 2491 | | |
2502 | 2492 | | |
2503 | 2493 | | |
| |||
2525 | 2515 | | |
2526 | 2516 | | |
2527 | 2517 | | |
2528 | | - | |
| 2518 | + | |
2529 | 2519 | | |
2530 | 2520 | | |
2531 | 2521 | | |
| |||
2929 | 2919 | | |
2930 | 2920 | | |
2931 | 2921 | | |
2932 | | - | |
| 2922 | + | |
2933 | 2923 | | |
2934 | 2924 | | |
2935 | 2925 | | |
| |||
3045 | 3035 | | |
3046 | 3036 | | |
3047 | 3037 | | |
3048 | | - | |
| 3038 | + | |
3049 | 3039 | | |
3050 | 3040 | | |
3051 | 3041 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2956 | 2956 | | |
2957 | 2957 | | |
2958 | 2958 | | |
| 2959 | + | |
| 2960 | + | |
| 2961 | + | |
| 2962 | + | |
| 2963 | + | |
| 2964 | + | |
2959 | 2965 | | |
2960 | 2966 | | |
2961 | 2967 | | |
| |||
2982 | 2988 | | |
2983 | 2989 | | |
2984 | 2990 | | |
| 2991 | + | |
2985 | 2992 | | |
2986 | 2993 | | |
2987 | 2994 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
169 | 169 | | |
170 | 170 | | |
171 | 171 | | |
172 | | - | |
| 172 | + | |
173 | 173 | | |
174 | 174 | | |
175 | 175 | | |
| |||
0 commit comments