Commit 79b0a7e
authored
[CSDiagnostics] Emit fix-its to insert requirement stubs for missing protocols in context (#33628)
* [CSDiagnostics] Emit fix-its to insert requirement stubs in editor mode for missing protocols in context
* [CSDiagnostics] Only include missing requirements in stub fix-it for missing protocols in context
The conforming type may already have declarations that could satisfy a requirement, so we shouldn't include it in the fix-it1 parent 48a7bc9 commit 79b0a7e
File tree
3 files changed
+87
-10
lines changed- include/swift/AST
- lib/Sema
- test/decl/protocol
3 files changed
+87
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
465 | 465 | | |
466 | 466 | | |
467 | 467 | | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
468 | 473 | | |
469 | 474 | | |
470 | 475 | | |
471 | | - | |
472 | | - | |
473 | | - | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
474 | 480 | | |
475 | 481 | | |
476 | 482 | | |
477 | 483 | | |
478 | | - | |
479 | | - | |
480 | | - | |
481 | | - | |
482 | | - | |
483 | 484 | | |
484 | 485 | | |
485 | 486 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| 20 | + | |
20 | 21 | | |
21 | 22 | | |
| 23 | + | |
22 | 24 | | |
23 | 25 | | |
24 | 26 | | |
| |||
2768 | 2770 | | |
2769 | 2771 | | |
2770 | 2772 | | |
| 2773 | + | |
2771 | 2774 | | |
2772 | 2775 | | |
2773 | 2776 | | |
| 2777 | + | |
2774 | 2778 | | |
2775 | 2779 | | |
2776 | 2780 | | |
| |||
2792 | 2796 | | |
2793 | 2797 | | |
2794 | 2798 | | |
2795 | | - | |
2796 | | - | |
2797 | 2799 | | |
2798 | 2800 | | |
2799 | 2801 | | |
| |||
2808 | 2810 | | |
2809 | 2811 | | |
2810 | 2812 | | |
| 2813 | + | |
| 2814 | + | |
| 2815 | + | |
| 2816 | + | |
| 2817 | + | |
| 2818 | + | |
| 2819 | + | |
| 2820 | + | |
| 2821 | + | |
| 2822 | + | |
| 2823 | + | |
| 2824 | + | |
| 2825 | + | |
| 2826 | + | |
| 2827 | + | |
| 2828 | + | |
| 2829 | + | |
| 2830 | + | |
| 2831 | + | |
| 2832 | + | |
| 2833 | + | |
| 2834 | + | |
| 2835 | + | |
| 2836 | + | |
| 2837 | + | |
| 2838 | + | |
| 2839 | + | |
| 2840 | + | |
| 2841 | + | |
2811 | 2842 | | |
2812 | 2843 | | |
2813 | 2844 | | |
| |||
Lines changed: 45 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
0 commit comments