diff --git a/docs/release-notes/.FSharp.Compiler.Service/9.0.100.md b/docs/release-notes/.FSharp.Compiler.Service/9.0.100.md index 0d56900dff3..f01e40cafc0 100644 --- a/docs/release-notes/.FSharp.Compiler.Service/9.0.100.md +++ b/docs/release-notes/.FSharp.Compiler.Service/9.0.100.md @@ -15,7 +15,7 @@ * Parser: recover on missing union case fields (PR [#17452](https://github.com/dotnet/fsharp/pull/17452)) * Parser: recover on missing union case field types (PR [#17455](https://github.com/dotnet/fsharp/pull/17455)) * Sink: report function domain type ([PR #17470](https://github.com/dotnet/fsharp/pull/17470)) -* Allow access modifies to auto properties getters and setters ([PR 16687](https://github.com/dotnet/fsharp/pull/16687), [PR 16861](https://github.com/dotnet/fsharp/pull/16861), [Language suggestion #430](https://github.com/fsharp/fslang-suggestions/issues/430)) +* Allow access modifies to auto properties getters and setters ([Language suggestion #430](https://github.com/fsharp/fslang-suggestions/issues/430), [PR 16687](https://github.com/dotnet/fsharp/pull/16687), [PR 16861](https://github.com/dotnet/fsharp/pull/16861), [PR 17522](https://github.com/dotnet/fsharp/pull/17522)) * Render C# nullable-analysis attributes in tooltips ([PR #17485](https://github.com/dotnet/fsharp/pull/17485)) ### Changed diff --git a/docs/release-notes/.Language/preview.md b/docs/release-notes/.Language/preview.md index 28e820d4ae8..9359ac25d82 100644 --- a/docs/release-notes/.Language/preview.md +++ b/docs/release-notes/.Language/preview.md @@ -7,7 +7,7 @@ * Bidirectional F#/C# interop for 'unmanaged' constraint. ([PR #12154](https://github.com/dotnet/fsharp/pull/12154)) * Make `.Is*` discriminated union properties visible. ([Language suggestion #222](https://github.com/fsharp/fslang-suggestions/issues/222), [PR #16341](https://github.com/dotnet/fsharp/pull/16341)) * Allow returning bool instead of unit option for partial active patterns. ([Language suggestion #1041](https://github.com/fsharp/fslang-suggestions/issues/1041), [PR #16473](https://github.com/dotnet/fsharp/pull/16473)) -* Allow access modifies to auto properties getters and setters ([PR 16687](https://github.com/dotnet/fsharp/pull/16687), [PR 16861](https://github.com/dotnet/fsharp/pull/16861), [Language suggestion #430](https://github.com/fsharp/fslang-suggestions/issues/430)) +* Allow access modifies to auto properties getters and setters ([Language suggestion #430](https://github.com/fsharp/fslang-suggestions/issues/430), [PR 16687](https://github.com/dotnet/fsharp/pull/16687), [PR 16861](https://github.com/dotnet/fsharp/pull/16861), [PR 17522](https://github.com/dotnet/fsharp/pull/17522)) * Allow #nowarn to support the FS prefix on error codes to disable warnings ([Issue #17206](https://github.com/dotnet/fsharp/issues/16447), [PR #17209](https://github.com/dotnet/fsharp/pull/17209)) * Allow ParsedHashDirectives to have argument types other than strings ([Issue #17240](https://github.com/dotnet/fsharp/issues/16447), [PR #17209](https://github.com/dotnet/fsharp/pull/17209)) * Support empty-bodied computation expressions. ([Language suggestion #1232](https://github.com/fsharp/fslang-suggestions/issues/1232), [PR #17352](https://github.com/dotnet/fsharp/pull/17352)) diff --git a/src/Compiler/FSComp.txt b/src/Compiler/FSComp.txt index 293317c9c13..e452d21f100 100644 --- a/src/Compiler/FSComp.txt +++ b/src/Compiler/FSComp.txt @@ -1771,10 +1771,10 @@ featureReuseSameFieldsInStructUnions,"Share underlying fields in a [] di 3868,tcActivePatternArgsCountNotMatchOnlyPat,"This active pattern expects exactly one pattern argument, e.g., '%s pat'." 3868,tcActivePatternArgsCountNotMatchArgs,"This active pattern expects %d expression argument(s), e.g., '%s%s'." 3868,tcActivePatternArgsCountNotMatchArgsAndPat,"This active pattern expects %d expression argument(s) and a pattern argument, e.g., '%s%s pat'." -featureAllowAccessModifiersToAutoPropertiesGettersAndSetters,"Allow access modifiers to auto properties getters and setters" -3869,tcAccessModifiersNotAllowedInSRTPConstraint,"Access modifiers cannot be applied to an SRTP constraint." featureParsedHashDirectiveArgumentNonString,"# directives with non-quoted string arguments" -3870,featureParsedHashDirectiveUnexpectedInteger,"Unexpected integer literal '%d'." -3870,featureParsedHashDirectiveUnexpectedIdentifier,"Unexpected identifier '%s'." +3869,featureParsedHashDirectiveUnexpectedInteger,"Unexpected integer literal '%d'." +3869,featureParsedHashDirectiveUnexpectedIdentifier,"Unexpected identifier '%s'." featureEmptyBodiedComputationExpressions,"Support for computation expressions with empty bodies: builder {{ }}" 3870,parsExpectingUnionCaseField,"Expecting union case field" +featureAllowAccessModifiersToAutoPropertiesGettersAndSetters,"Allow access modifiers to auto properties getters and setters" +3871,tcAccessModifiersNotAllowedInSRTPConstraint,"Access modifiers cannot be applied to an SRTP constraint." diff --git a/src/Compiler/SyntaxTree/SyntaxTree.fsi b/src/Compiler/SyntaxTree/SyntaxTree.fsi index 88529957c25..9c7b83083df 100644 --- a/src/Compiler/SyntaxTree/SyntaxTree.fsi +++ b/src/Compiler/SyntaxTree/SyntaxTree.fsi @@ -1489,7 +1489,7 @@ type SynComponentInfo = /// Gets the syntax range of this construct member Range: range -/// Represents two access +/// Represents one or two access modifier(s) in a property signature [] type SynValSigAccess = | Single of accessibility: SynAccess option diff --git a/tests/FSharp.Compiler.ComponentTests/Conformance/Types/TypeConstraints/IWSAMsAndSRTPs/IWSAMsAndSRTPsTests.fs b/tests/FSharp.Compiler.ComponentTests/Conformance/Types/TypeConstraints/IWSAMsAndSRTPs/IWSAMsAndSRTPsTests.fs index a02ce93e498..5b89dfddc81 100644 --- a/tests/FSharp.Compiler.ComponentTests/Conformance/Types/TypeConstraints/IWSAMsAndSRTPs/IWSAMsAndSRTPsTests.fs +++ b/tests/FSharp.Compiler.ComponentTests/Conformance/Types/TypeConstraints/IWSAMsAndSRTPs/IWSAMsAndSRTPsTests.fs @@ -1282,10 +1282,10 @@ let inline length4 (x: ^a when ^a: (member public get_Length: unit -> int)) = x. |> typecheck |> shouldFail |> withDiagnostics [ - (Error 3869, Line 2, Col 43, Line 2, Col 49, "Access modifiers cannot be applied to an SRTP constraint.") - (Error 3869, Line 3, Col 61, Line 3, Col 67, "Access modifiers cannot be applied to an SRTP constraint.") - (Error 3869, Line 4, Col 61, Line 4, Col 67, "Access modifiers cannot be applied to an SRTP constraint.") - (Error 3869, Line 5, Col 44, Line 5, Col 50, "Access modifiers cannot be applied to an SRTP constraint.") + (Error 3871, Line 2, Col 43, Line 2, Col 49, "Access modifiers cannot be applied to an SRTP constraint.") + (Error 3871, Line 3, Col 61, Line 3, Col 67, "Access modifiers cannot be applied to an SRTP constraint.") + (Error 3871, Line 4, Col 61, Line 4, Col 67, "Access modifiers cannot be applied to an SRTP constraint.") + (Error 3871, Line 5, Col 44, Line 5, Col 50, "Access modifiers cannot be applied to an SRTP constraint.") ] [] @@ -1300,10 +1300,10 @@ let inline length4 (x: ^a when ^a: (member public get_Length: unit -> int)) = x. |> typecheck |> shouldFail |> withDiagnostics [ - (Warning 3869, Line 2, Col 43, Line 2, Col 49, "Access modifiers cannot be applied to an SRTP constraint.") - (Warning 3869, Line 3, Col 61, Line 3, Col 67, "Access modifiers cannot be applied to an SRTP constraint.") - (Warning 3869, Line 4, Col 61, Line 4, Col 67, "Access modifiers cannot be applied to an SRTP constraint.") - (Warning 3869, Line 5, Col 44, Line 5, Col 50, "Access modifiers cannot be applied to an SRTP constraint.") + (Warning 3871, Line 2, Col 43, Line 2, Col 49, "Access modifiers cannot be applied to an SRTP constraint.") + (Warning 3871, Line 3, Col 61, Line 3, Col 67, "Access modifiers cannot be applied to an SRTP constraint.") + (Warning 3871, Line 4, Col 61, Line 4, Col 67, "Access modifiers cannot be applied to an SRTP constraint.") + (Warning 3871, Line 5, Col 44, Line 5, Col 50, "Access modifiers cannot be applied to an SRTP constraint.") ] [] diff --git a/tests/FSharp.Compiler.ComponentTests/ErrorMessages/Directives.fs b/tests/FSharp.Compiler.ComponentTests/ErrorMessages/Directives.fs index b2c73b12b39..14377fbe8b3 100644 --- a/tests/FSharp.Compiler.ComponentTests/ErrorMessages/Directives.fs +++ b/tests/FSharp.Compiler.ComponentTests/ErrorMessages/Directives.fs @@ -275,10 +275,10 @@ printfn "Hello, World" |> asExe |> compile |> shouldFail - |> withDiagnostics[ + |> withDiagnostics [ (Warning 3353, Line 2, Col 9, Line 2, Col 11, "Invalid directive '#r '") (Warning 213, Line 3, Col 9, Line 3, Col 14, "'' is not a valid assembly name") - (Error 3870, Line 4, Col 12, Line 4, Col 17, "Unexpected identifier 'Ident'.") - (Error 3870, Line 5, Col 12, Line 5, Col 22, "Unexpected identifier 'Long.Ident'.") - (Error 3870, Line 6, Col 12, Line 6, Col 15, "Unexpected integer literal '123'.") - ] + (Error 3869, Line 4, Col 12, Line 4, Col 17, "Unexpected identifier 'Ident'.") + (Error 3869, Line 5, Col 12, Line 5, Col 22, "Unexpected identifier 'Long.Ident'.") + (Error 3869, Line 6, Col 12, Line 6, Col 15, "Unexpected integer literal '123'.") + ]