-
Notifications
You must be signed in to change notification settings - Fork 334
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add type hierarchy support #779
Conversation
Type hierarchy provider is already in vscode, I'm going to refine this PR based on that. One question is, do I have to move TypeHierarchy into proposed namespace (same as Diagnostics) or just keep it as is? |
@Eskibear it has to go to the proposed namespace fist although it is available in VS Code. |
Signed-off-by: Yan Zhang <[email protected]>
d21122b
to
866a83f
Compare
@Eskibear in which state is this PR. It is marked as a draft and it does have duplicate files (e.g. server typeHierarchy.ts and proposed.typeHierarchy.ts) Are you planning on finishing the PR. I think we can merge it this month and create a new LSP release to contain it. |
It's almost done. I just want to do some E2E verification before I mark it ready to review. BTW is there any convenient way to create a private npm package for testing purpose? Due to the dependencies (client -> protocol -> types), previously to verify it E2E, I have to bump versions and create npm packs one-by-one, install them locally... and change the relative path to version number accordingly. |
Signed-off-by: Yan Zhang <[email protected]>
I just tested with a mock LS for plaintext. Both "Show Type Hierarchy" and "Peek Type Hierarchy" work fine. The only problem is, when I use |
E2E smoke test against Java LS: type-hierarchy-e2e.mp4 |
Cool. Thanks for providing this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The rest looks good to me
Signed-off-by: Yan Zhang <[email protected]>
This is a prototype to support type hierarchy proposed in microsoft/language-server-protocol#1231
Because there is no implementation of type hierarchy providers and related APIs in VS Code, I have to implement a simple one here, immitating provider registration in VS Code core.
Changes are mainly two parts:
Implemetation of type hierarchy providers, which should eventually be moved to (re-implemented in) vscode core.already available invscode.proposed.d.ts
since v1.59Status of this PR:
I'm still working on it. The draft PR is created for early review of the feasibility.Any critical problem or obvious mistake about the whole workflow, please let me know.