-
Notifications
You must be signed in to change notification settings - Fork 830
VS: use JoinableTaskFactory for Quickinfo link navigation #15087
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
Conversation
|
Thanks! This is going to be a valuable UX improvement. I'd like to clarify a few things:
|
Should be.
Yeah, I was not very precise. Historically this feature started very thin. Niceprint in the compiler augmented the taggedtext with ranges, and given the range you could very quickly navigate to the textspan. This is now The slower path is the one that tries to find the implementation based on signature, this involves sometimes waiting for a type check, I suppose.
I've seen it fail in VisualFsharp.sln when navigating from Editor to FSharp.Core.
Just personal taste :) The default 2 seconds felt a bit too long time to not have any feedback. OTOH it seems aything less than a second gets rounded down to 0. |
Specifically, to trigger this, try navigating to something crazy like |
Ohhh that's where you should have started! That's awesome, didn't think we have such a basic thing broken. Anyway, it should be good then. I'd still ask to explain or elaborate on the terms "fast" and "slow" in the code/comments, otherwise - great job! |
|
I updated the comments to make it less cryptic :) |
|
Cool! |
…nto quickinfo-links
Head branch was pushed to by a user without write access
QuickInfo links navigation have a slow path and a fast path.
Navigating to the range provided by the
ToolTipTextis fast / instant.We have also logic that tries to navigate to .fs implementation in case the starting point (where the QuickInfo was triggered) is in an implementation file. This can take a type check and a lot of time in cases when navigating to another project.
JoinableTaskFactory.Runoverload will display a standard dialog and allow for cancellation when link navigation is taking too long:Also fixed the situation when this slower path silently fails in some cases. Now it falls back to the fast path (i.e. goes to .fsi, which is fast).