sublimelsp / LSP-rust-analyzer

Convenience package for rust-analyzer

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Up arrow sometimes moves up two lines when CodeLens is enabled

ThatsNoMoon opened this issue · comments

I don't have a lot more information than what's in the title. Here's an example of the behavior I'm seeing:

njEPtbhlPu.mp4

It's very particular; for example, if I use fn main() {} instead of that test, it doesn't happen, despite an extremely similar link appearing.

It does always seem to be dependent on being between some set of CodeLens links, but I can't tell when or what links cause it to happen consistently.

Here's the code I used. It seems to reproduce the behavior I'm seeing consistently.

pub struct Foo;
#[test]
fn foo() {}

(add spacing as necessary to be able to see the effect)

I've also noticed it seems to always stop before getting to a line with another CodeLens link. I.E, it won't skip a line to land on a line with a CodeLens link, it will just go up one line to land on the line before it.

I would like to have CodeLens enabled, but I've disabled it for now because of this issue. Let me know if I can provide any other information.

Which ST version?

Build 4121.

Worth checking in latest dev build since there were some related phantom fixes there. Or wait for next stable build.

Hmm, yeah. I don't have a license, unfortunately, so I'll wait on a stable release, myself. Thanks for the suggestion, I hadn't thought about it being a ST issue, since I don't have phantoms enabled for any other plugins.

This seems to have been fixed in the latest stable build. Thanks again for your input.