Is your feature request related to a problem? Please describe.
In Visual Studio, F# projects build with the .NET Framework compiler bundled in VS, while dotnet build uses the .NET SDK compiler. The two can differ, so the same project can behave differently in VS than on the command line — and there is no UI to control which is used.
Describe the solution you'd like
A Tools → Options → F# Tools → Compiler checkbox "Use the .NET SDK F# compiler for builds", on by default, so VS matches dotnet build. Turn it off to fall back to the Visual Studio (.NET Framework) compiler.
Additional context
VS-only; command-line builds are unaffected.
Risks to be aware of:
- Editor vs build divergence: Visual Studio's background analysis (IntelliSense, error squiggles, the in-process type checker) runs on .NET Framework and is not affected by this option — it always uses the VS-hosted compiler. With the option on, your build uses the SDK compiler while design-time editor feedback still uses the VS compiler, so if the two compiler versions differ you may occasionally see build results that don't match the editor.
- .NET Framework type providers: a project depending on a type provider whose design-time component ships only for .NET Framework must turn this option off to build — the SDK compiler can't load a .NET-Framework-only design-time assembly.
Is your feature request related to a problem? Please describe.
In Visual Studio, F# projects build with the .NET Framework compiler bundled in VS, while
dotnet builduses the .NET SDK compiler. The two can differ, so the same project can behave differently in VS than on the command line — and there is no UI to control which is used.Describe the solution you'd like
A Tools → Options → F# Tools → Compiler checkbox "Use the .NET SDK F# compiler for builds", on by default, so VS matches
dotnet build. Turn it off to fall back to the Visual Studio (.NET Framework) compiler.Additional context
VS-only; command-line builds are unaffected.
Risks to be aware of: