-
Notifications
You must be signed in to change notification settings - Fork 313
Closed
Description
Description
When the property <TreatWarningsAsErrors>true</TreatWarningsAsErrors> is included in the fsproj file, the Fable compiler still issues warnings instead of errors.
Repro code
Test.fsproj
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
</PropertyGroup>
<ItemGroup>
<Compile Include="Library.fs" />
</ItemGroup>
</Project>Library.fs
module WarnAsErrorTest
type Message = Load | Save | Exit
let message =
function
| Load -> printfn "Loading"
| Save -> printfn "Saving"Expected and actual results
Expected
Running dotnet fable should print an error message.
Actual
Running dotnet build does print an error message.
Running dotnet fable does not print an error message.
Related information
- Fable version:
dotnet fable --version: 3.2.12 - Operating system: Windows
jfaixolo, inosik and danilbrenner
Metadata
Metadata
Assignees
Labels
No labels