This repository was archived by the owner on Nov 21, 2025. It is now read-only.
Commit 7c22c4c
committed
fix(server): Only provide InsertReplaceEdit when the client supports it (#1452)
From the spec:
>Most editors support two different operations when accepting a completion
>item. One is to insert a completion text and the other is to replace an
>existing text with a completion text. Since this can usually not be
>predetermined by a server it can report both ranges. Clients need to
>signal support for InsertReplaceEdits via the
>textDocument.completion.completionItem.insertReplaceSupport client
>capability property.
Fixes #1451
(cherry picked from commit bccefd3)1 parent 5cd801b commit 7c22c4c
File tree
3 files changed
+31
-17
lines changed- integration/lsp
- server/src
3 files changed
+31
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
247 | 247 | | |
248 | 248 | | |
249 | 249 | | |
250 | | - | |
251 | | - | |
252 | | - | |
253 | | - | |
| 250 | + | |
| 251 | + | |
254 | 252 | | |
255 | 253 | | |
256 | 254 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
103 | 103 | | |
104 | 104 | | |
105 | 105 | | |
106 | | - | |
107 | | - | |
| 106 | + | |
| 107 | + | |
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
| |||
118 | 118 | | |
119 | 119 | | |
120 | 120 | | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | | - | |
127 | | - | |
128 | | - | |
129 | | - | |
130 | | - | |
| 121 | + | |
| 122 | + | |
131 | 123 | | |
132 | 124 | | |
133 | 125 | | |
134 | 126 | | |
135 | 127 | | |
136 | 128 | | |
137 | 129 | | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| 68 | + | |
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
| |||
576 | 577 | | |
577 | 578 | | |
578 | 579 | | |
| 580 | + | |
579 | 581 | | |
580 | 582 | | |
581 | 583 | | |
| |||
969 | 971 | | |
970 | 972 | | |
971 | 973 | | |
| 974 | + | |
| 975 | + | |
| 976 | + | |
972 | 977 | | |
973 | | - | |
| 978 | + | |
| 979 | + | |
974 | 980 | | |
975 | 981 | | |
976 | 982 | | |
| |||
0 commit comments