dotnet / fsharp

The F# compiler, F# core library, F# language service, and F# tooling integration for Visual Studio
https://dotnet.microsoft.com/languages/fsharp
MIT License
3.82k stars 773 forks source link

Add tooltips for the hints #14268

Open psfinaki opened 1 year ago

psfinaki commented 1 year ago

Can hints themselves have tooltips? This here looks like an empty one:

image

It would be nice to reuse type annotation tooltips with all the good stuff like clickable references:

image

Looks like a function needs to be passed in https://github.com/dotnet/roslyn/blob/315c2e149ba7889b0937d872274c33fcbfe9af5f/src/Tools/ExternalAccess/FSharp/InlineHints/FSharpInlineHint.cs

Originally posted by @kerams in https://github.com/dotnet/fsharp/issues/14157#issuecomment-1306019663

cartermp commented 1 year ago

I remember trying to spike on this a while back -- I don't remember exactly, but if there's some notion of a position, then you can refactor the quickinfo bits and pass that in. But I recall at the time it needing to be able to resolve a symbol in some way that the compiler service couldn't do.

psfinaki commented 1 year ago

@cartermp thanks for the info, this is useful.

btw @kerams by chance, is this something you would be interested in implementing? It's absolutely fine if no, just asking to avoid possible double work.

kerams commented 1 year ago

No, not really.

psfinaki commented 1 year ago

Not closing this one since there is a lot to be improved in this space, see the screenshot in the issue desc.