lsp: Fix `vtsls` `completeFunctionCalls` setting being ignored (#53285)

Some language servers (notably `vtsls` with `completeFunctionCalls`)
update `insertText/textEdit` during `completionItem/resolve` to add
snippet content like function call parentheses. Previously,
`Completion.new_text` was only set from the initial completion response
and never re-derived after resolve, so the snippet text was silently
discarded.

Re-derive `new_text` from the resolved `lsp_completion`. Only the text
content is updated -- replace/insert ranges are left as anchors from the
original response since the LSP ranges in the resolved text_edit are
stale when completions are cached across keystrokes (re: #34094).

Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [ ] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable

Closes #53275.

Release Notes:

- Fixed the `vtsls` `completeFunctionCalls` setting being ignored
96eb05166fKunall Banerjee committed on 4/23/2026, 12:02:11 PM· committed by GitHubparent9e435c0
1 file changedLine totals unavailable