Closed
Description
Visual Studio 2017 with the latest Updates shows "Open declaration can be removed" suggestion even when a type from the opened module is used.
Repro steps
Put the following code into an .fsx
file and open it in Visual Studio. The line open DeclaresA
will be grayed out.
module DeclaresA =
type A = class end
module UsesA =
open DeclaresA
let a = Unchecked.defaultof<A>
Expected behavior
It should not be grayed out.
Actual behavior
It is grayed out, the tooling thinks nothing of the opened module is used.
Known workarounds
Since it is just a suggestion, simply ignoring it works.
Related information
- Windows 10
- .NET 4.5
- Visual Studio 2017 with all Updates installed