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

[RFC] Do not use a full line as description for symbol search #1726

Merged
merged 1 commit into from Jan 14, 2024

Conversation

bstaletic
Copy link
Collaborator

@bstaletic bstaletic commented Jan 9, 2024

This does lose a bit of context, but not much. Methods still have their signatures visible and variables are... well... variables.

The idea is, if a client wants to later do filtering and sorting of symbols, we should not be doing that on the whole line, which might be left padded with tabs and have other punctuation. We already had a report that this does not work well. It almost works if a client strip()s the description before using it at all.

LSP completer instead uses extra_data to supply identifier name and kind, but omnisharp-roslyn does not provide us with a symbol kind and thus we can only put ref[ 'Text' ] in the description.

@teasp00n was the user who pointed out the problems with using the whole line for filtering.


This change is Reviewable

This does lose a bit of context, but not much. Methods still have their
signatures visible and variables are... well... variables.

The idea is, if a client wants to later do filtering and sorting of
symbols, we should not be doing that on the whole line, which might be
left padded with tabs and have other punctuation. We already had a
report that this does not work well. It almost works if a client
`strip()`s the description before using it at all.

LSP completer instead uses `extra_data` to supply identifier name and
kind, but omnisharp-roslyn does not provide us with a symbol kind and
thus we can only put `ref[ 'Text' ]` in the description.
Copy link
Member

@puremourning puremourning left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

Reviewed 1 of 1 files at r1, all commit messages.
Reviewable status: 1 of 2 LGTMs obtained (waiting on @bstaletic)

@bstaletic bstaletic added the Ship It! Manual override to merge a PR by maintainer label Jan 14, 2024
Copy link
Contributor

mergify bot commented Jan 14, 2024

Thanks for sending a PR!

@mergify mergify bot merged commit eeaf205 into ycm-core:master Jan 14, 2024
14 of 15 checks passed
@bstaletic bstaletic deleted the cs_symbol_search branch January 14, 2024 20:29
bstaletic added a commit to ycm-core/YouCompleteMe that referenced this pull request Feb 18, 2024
Changes since the last update:

ycm-core/ycmd#1728 YcmShowDetailedDiagnostic should now match what is echoed on the command line.
ycm-core/ycmd#1731 Add support for `workspace/didChangeWorkspaceFolders` LSP notification.
ycm-core/ycmd#1730 LSP servers are now updated with latest server state afer reset
ycm-core/ycmd#1727 Update JDT to version 1.31.0
ycm-core/ycmd#1726 C# symbol search filtering fix
ycm-core/ycmd#1724 C# GoToDocumentOutline consistency patch
ycm-core/ycmd#1723 Implement GoToDocumentOutline in C#
ycm-core/ycmd#1716 Display tsserver tags in detailed info and GetDoc

`workspace/didChangeWorkspaceFolders` seems to be working fine for java,
rust and go, but should be considered experimental. Definitely more
field experience is needed.
What it should do is allow LSP servers to understand multiple projects
in the same vim instance.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Ship It! Manual override to merge a PR by maintainer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants