-
Notifications
You must be signed in to change notification settings - Fork 4
Conversation
- extracting data to display in "find references" panel. Reading files from FS and extracting Nth line using reference location spans. Caching files read and line offsets - using symbol name as 'symbol display string' to avoid 'quickinfo' requests
# Conflicts: # README.md
- to unblock message receiving thread, decorating references (by adding `lineText` attribute) in a separate thread
- added support for `textDocument/hover` w/o range - `initialize` request should pass path instead of URI as parameter - errors handling in "find references" - corrected parameters passed to `textDocument/references` - thou should not rely on `view.match_selector` because there might be no such selector available (language is not registrered) or language name and aliases do not match extension
Conflicts: README.md typescript/commands/references.py typescript/libs/lsp_client.py typescript/libs/view_helpers.py
What is the current status of getting this support merged in? |
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
finally: | ||
if f is not None: | ||
f.close() | ||
class RefsHelper: |
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.
I remember we talked about this one before - either approach seems fine, I just worry about the performance implications of this approach.
__lines and __content will be maps that contain every file and every file -> line mapping for all references simultaneously, which seems like it could blow up memory usage.
That being said, it's easier to debug and reason about, so can understand that approach. And, it's just text.
Have you tried on an example with 100 reference files (some stdlib thing)?
@uforic sorry for this, your commits addressing this were lost by mistake, I have restored them now. |
Does anyone have a sec to explain how this works? I tried installing the latest checkout from git and I see this in the console when I try to open a rust file: 2017-03-06 10:26:35,711: 140737142133696: DEBUG: Looking for client for extension rs in /Users/jturner/Source/httparse Are there additional steps I need to do for rls support? |
@jonathandturner please try to:
|
@alexsaveliev - great! I had to do a few workarounds to get it to work, but your tip helped me. In case anyone was curious, I had to make a script:
And then add this to my "preferences -> Sublime LSP connector -> plugin settings - user":
|
addresses #11, I have tested the following LSP requests on https://github.com/RalfJung/rust-101: