diff --git a/src/Compiler/Driver/CompilerDiagnostics.fs b/src/Compiler/Driver/CompilerDiagnostics.fs index 0ec2a8ce98b..bd3624437c5 100644 --- a/src/Compiler/Driver/CompilerDiagnostics.fs +++ b/src/Compiler/Driver/CompilerDiagnostics.fs @@ -387,6 +387,7 @@ type PhasedDiagnostic with | 3390 -> false // xmlDocBadlyFormed - off by default | 3395 -> false // tcImplicitConversionUsedForMethodArg - off by default | 3559 -> false // typrelNeverRefinedAwayFromTop - off by default + | 3560 -> false // tcCopyAndUpdateRecordChangesAllFields - off by default | 3579 -> false // alwaysUseTypedStringInterpolation - off by default | _ -> match x.Exception with diff --git a/tests/FSharp.Compiler.ComponentTests/Diagnostics/Records.fs b/tests/FSharp.Compiler.ComponentTests/Diagnostics/Records.fs index 70dcd710e34..ff741d40ea6 100644 --- a/tests/FSharp.Compiler.ComponentTests/Diagnostics/Records.fs +++ b/tests/FSharp.Compiler.ComponentTests/Diagnostics/Records.fs @@ -17,6 +17,7 @@ let updateOk r = { r with F1 = 1 } let updateWarn r = { r with F1 = 1; F2 = "" } """ |> withLangVersion80 + |> withOptions ["--warnon:FS3560"] |> typecheck |> shouldFail |> withDiagnostics [ @@ -46,7 +47,6 @@ type R = { F1: int; F2: string } let updateWarn r = { r with F1 = 1; F2 = "" } """ |> withLangVersion80 - |> withOptions ["--nowarn:3560"] |> typecheck |> shouldSucceed @@ -86,6 +86,7 @@ let t2 (x: RecTy) (a: AnotherNestedRecTy) = { x with D.C.c = { a with A = 3 } } let t3 (x: RecTy) (a: AnotherNestedRecTy) = { x with D.C.c = { a with A = 3; B = 4 } } """ |> withLangVersion80 + |> withOptions ["--warnon:FS3560"] |> typecheck |> shouldFail |> withDiagnostics [