dotnet / dotnet/fsharp

Hovering over an F# function shows the wrong type

Open
#12,074 0 comments 0 reactions 0 assignees View on GitHub
Area-LangService-ToolTips Bug Impact-Low
Dominant language
F#
Stars
4.3k
Forks
876
Avg merge
4d 11h
Merged PRs (30d)
131

Description

_This issue has been moved from [a ticket on Developer Community](https://developercommunity.visualstudio.com/t/Hovering-over-an-F-function-shows-the-w/1499816)._

---
[severity:It's more difficult to complete my work]
When hovering over this F# function Visual Studio shows the wrong type:

let retryHttp<'a>
(detectScenario : HttpScenario -> HttpResponseScenario<'a>)
retryPolicy
fixPolicy
(request : unit -> Task)
: Task> =

(Function body not shown.)

When hovering over this function, this is what I see:

![Bafb06f3c54944915a0197d60a7f257f1637642624828874442_20210811-090801-image](https://user-images.githubusercontent.com/7204669/131725060-115c286e-fa37-4e36-b8d3-a4e0b982bda8.png)

Notice that the `request` is shown as `unit ->Result Task` while the return type of the function is shown as `Task<<'a,RetriesStoppedReason>>`. Both are incorrect based on the function declaration, and are, in fact, not even valid F# types.

---
### Original Comments

#### Feedback Bot on 8/12/2021, 00:25 AM:

We have directed your feedback to the appropriate engineering team for further evaluation. The team will review the feedback and notify you about the next steps.

---
### Original Solutions
(no solutions)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.