-
Notifications
You must be signed in to change notification settings - Fork 118
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 find refs #721
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
amyXia1994
force-pushed
the
feat/find-refs
branch
from
September 19, 2023 12:41
01c5dc8
to
b8cdc93
Compare
amyXia1994
force-pushed
the
feat/find-refs
branch
from
September 20, 2023 02:14
f446ba8
to
4136d95
Compare
Pull Request Test Coverage Report for Build 6493910165
💛 - Coveralls |
amyXia1994
force-pushed
the
feat/find-refs
branch
from
September 20, 2023 08:14
ff0709c
to
1bdd5c8
Compare
He1pa
reviewed
Sep 21, 2023
NeverRaR
reviewed
Sep 21, 2023
Peefy
reviewed
Sep 23, 2023
amyXia1994
force-pushed
the
feat/find-refs
branch
3 times, most recently
from
October 12, 2023 09:34
e9e9e63
to
bd435a2
Compare
Signed-off-by: xiarui.xr <[email protected]>
Signed-off-by: xiarui.xr <[email protected]>
Signed-off-by: xiarui.xr <[email protected]>
Signed-off-by: xiarui.xr <[email protected]>
Signed-off-by: xiarui.xr <[email protected]>
Signed-off-by: xiarui.xr <[email protected]>
Signed-off-by: xiarui.xr <[email protected]>
Signed-off-by: xiarui.xr <[email protected]>
Signed-off-by: xiarui.xr <[email protected]>
Signed-off-by: xiarui.xr <[email protected]>
amyXia1994
force-pushed
the
feat/find-refs
branch
from
October 12, 2023 09:35
bd435a2
to
0d76b7a
Compare
amyXia1994
force-pushed
the
feat/find-refs
branch
3 times, most recently
from
October 12, 2023 11:28
82fa377
to
85771f4
Compare
Signed-off-by: xiarui.xr <[email protected]>
amyXia1994
force-pushed
the
feat/find-refs
branch
from
October 12, 2023 11:30
85771f4
to
eae36e2
Compare
Peefy
approved these changes
Oct 12, 2023
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.
LGTM
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
1. Does this PR affect any open issues?(Y/N) and add issue references (e.g. "fix #123", "re #123".):
re [Feature] support find reference token list from the definition #712
2. What is the scope of this PR (e.g. component or file name):
added: implement the find reference API and add some integration tests
kclvm/tools/src/LSP/src/find_refs.rs
kclvm/tools/src/LSP/src/test_data/find_refs_test/...
modified:
kcl_pos
bug infrom_lsp.rs
Definition
enum, add a name field inkclvm/tools/src/LSP/src/goto_def.rs
and update relative usages of itkclvm/tools/src/LSP/src/capabilities.rs
kclvm/tools/src/LSP/src/completion.rs
kclvm/tools/src/LSP/src/from_lsp.rs
kclvm/tools/src/LSP/src/goto_def.rs
kclvm/tools/src/LSP/src/hover.rs
kclvm/tools/src/LSP/src/lib.rs
kclvm/tools/src/LSP/src/main.rs
kclvm/tools/src/LSP/src/request.rs
kclvm/tools/src/LSP/src/state.rs
kclvm/tools/src/LSP/src/tests.rs
kclvm/tools/src/LSP/src/util.rs
deleted: the older incomplete implementation attempt about find ref
kclvm/tools/src/LSP/src/find_ref/...
3. Provide a description of the PR(e.g. more details, effects, motivations or doc link):
Feat: lsp support basic find reference
Known flaws:
the performance in a large-scaled workspace is slow
the
scope
to find references needs to be narrowed down to min(workspace, kcl_package_root). now the find refs searches under the kcl package root(identified by the kcl.mod file)does not handle the include_declaration param. now always returns refs include declaration
the references of an imported package is not supported yet.
4. Are there any breaking changes?(Y/N) and describe the breaking changes(e.g. more details, motivations or doc link):
5. Are there test cases for these changes?(Y/N) select and add more details, references or doc links: