Skip to content

Fix LanguageClient.prepareRename() support for { defaultBehavior: true }#1748

Open
ndonfris wants to merge 1 commit intomicrosoft:mainfrom
ndonfris:fix/prepareRename-defaultBehavior
Open

Fix LanguageClient.prepareRename() support for { defaultBehavior: true }#1748
ndonfris wants to merge 1 commit intomicrosoft:mainfrom
ndonfris:fix/prepareRename-defaultBehavior

Conversation

@ndonfris
Copy link
Copy Markdown

  • /client behavior no longer converts { defaultBehavior: true } to null, to now match >= 3.16.0 specification

    • converts { defaultBehavior: true } into the editor's default word range, allowing textDocument/rename requests without widening the VS Code provider type
    • continues to reject { defaultBehavior: false }, preventing textDocument/rename requests
  • /client-node-tests new related prepareRename tests

    • adds test server coverage for a controlled { defaultBehavior: true } prepareRename response
    • adds a dedicated integration test asserting the client converts that server result into a vscode.Range while keeping the existing Rename test focused on the standard flow

…ue }`

* /client behavior no longer converts `{ defaultBehavior: true }` to `null`, to now match >= 3.16.0 specification

  - converts `{ defaultBehavior: true }` into the editor's default word range, allowing `textDocument/rename` requests without widening the VS Code provider type
  - continues to reject `{ defaultBehavior: false }`, preventing `textDocument/rename` requests

* /client-node-tests new related `prepareRename` tests

  - adds test server coverage for a controlled `{ defaultBehavior: true }` prepareRename response
  - adds a dedicated integration test asserting the client converts that server result into a vscode.Range while keeping the existing Rename test focused on the standard flow
@ndonfris
Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant