We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f325ba2 commit 6e6833aCopy full SHA for 6e6833a
1 file changed
tests/FSharp.Compiler.ComponentTests/ErrorMessages/WarnExpressionTests.fs
@@ -277,3 +277,19 @@ let main _argv =
277
"""
278
|> typecheck
279
|> shouldSucceed
280
+
281
+ // https://github.com/dotnet/fsharp/issues/4473
282
+ [<Fact>]
283
+ let ``Issue 4473 - extern function parameters not flagged as unused with warnon 1182``() =
284
+ FSharp """
285
+module Test4473
286
287
+open System.Runtime.InteropServices
288
289
+[<DllImport("kernel32.dll")>]
290
+extern bool Beep(int frequency, int duration)
291
+ """
292
+ |> withWarnOn 1182
293
+ |> asLibrary
294
+ |> typecheck
295
+ |> shouldSucceed
0 commit comments