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.88k stars 783 forks source link

Fix 17561 - FS0243 - Unrecognized option: '--realsig- #17562

Closed KevinRansom closed 1 month ago

KevinRansom commented 1 month ago

image

Repro: on a clean machine:

  1. Install Visual Studio 2022.11 --- https://visualstudio.microsoft.com/downloads/
  2. Install Dotnet Sdk 7.0.410 -- https://dotnet.microsoft.com/en-us/download/dotnet/7.0
  3. Create a new F# console project
  4. Edit the project file to resemble this:

    
    <Project Sdk="Microsoft.NET.Sdk">
    
    <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>net7.0</TargetFramework>
    <FSharpPreferNetFrameworkTools>False</FSharpPreferNetFrameworkTools>
    </PropertyGroup>
    
    <ItemGroup>
    <Compile Include="Program.fs" />
    </ItemGroup>


5. Build the project and observe this error:
![image](https://github.com/user-attachments/assets/62dcabd9-7d3d-42c5-85be-b3dcac01cfd6)

The issue is that the buildtask emits --realsig- even though the projectfile and dependent props and targets do not mention it.
This pr fixes the issue by not emiting a value when realsig has not been specified.

There is no decent work around, other than build from the command line using dotnet build.
github-actions[bot] commented 1 month ago

:white_check_mark: No release notes required