Tooling suggestion: show function's capture list on hover
- Dominant language
- F#
- Stars
- 4.3k
- Forks
- 876
- Avg merge
- 4d 11h
- Merged PRs (30d)
- 131
Description
## Suggestion
It would be nice if F# tooling could show a list of values captured by a given function, member (e.g., in object expressions), or lambda on hover. I have often wished for this feature when reading code as well as during refactoring.[^1]
E.g., given something like
```fsharp
let x = 3
let mutable y = 99
let f g = g x + y
```
I would want hovering over `f` to show that `x` and `y` were captured. I'd ideally also want it shown that `y` was captured as a mutable value.
## Additional context
The C# tooling has supported this for quite some time (via Roslyn).
[^1]: A capture-aware "extract/move function" feature would of course also be useful, but here I am only suggesting that we surface the information to the developer.
Contributor guide
Assessment
This issue has not been assessed yet.