Skip to content
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

feat: LSP support #54

Merged
merged 21 commits into from
Nov 30, 2024
Merged

feat: LSP support #54

merged 21 commits into from
Nov 30, 2024

Conversation

sminez
Copy link
Owner

@sminez sminez commented Nov 27, 2024

There is some discussion around this in #46

This is very definitely not aiming to provide support for all LSP features (nor is there any plan to do so in the future). Instead it is an attempt to support a useful subset of some of the more basic features of LSP that fit within the existing editing model of ad. This initial PR is not aiming to implement everything that is called out as in scope below but it should hopefully provide a reasonable starting point.

In scope:

  • hover ✅
  • go to definition ✅
  • go to ... ✅
  • show references ✅
  • rename

Explicitly out of scope:

  • semantic highlighting ❌
  • call hierarchy ❌
  • folding ranges ❌
  • inline hints ❌
  • inlay hints ❌

LSP features not called out above may be considered in the future but not at this time.

ad-lsp-demo-2024-11-30_19.02.13.mp4

Still need to sort out configuring which LSP to run rather than hard
coding to rust analyzer and the ad codebase but this is now a working
(very) minimal client. It looks like rust-analyzer needs to receiver a
first request for something before it will index the workspace so that
needs to be sorted out and there is a lot of cleanup to do around error
handling etc
@sminez sminez added the enhancement New feature or request label Nov 27, 2024
@sminez sminez marked this pull request as ready for review November 30, 2024 09:40
@sminez
Copy link
Owner Author

sminez commented Nov 30, 2024

There are still a fair amount of things to add beyond this (most importantly, the ability configure different LSP servers) but I'm aiming on merging the current state as it is in order to have a starting point rather than chasing down every remaining feature.

@sminez sminez merged commit 954ac31 into develop Nov 30, 2024
7 checks passed
@sminez sminez deleted the lsp-client branch November 30, 2024 22:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant