From 1799aaf29034f01357684c7716b6eed8fc76468a Mon Sep 17 00:00:00 2001 From: Edgar Gonzalez Date: Wed, 23 Apr 2025 15:27:24 +0100 Subject: [PATCH 01/10] make attribute targets mismatches a warning and not an error. --- .../Checking/Expressions/CheckExpressions.fs | 2 +- .../AttributeUsage/AttributeUsage.fs | 215 +++++++++--------- .../CustomAttributes/Basic/Basic.fs | 7 +- .../EntryPoint/EntryPoint.fs | 2 +- .../LetBindings/Basic/Basic.fs | 4 +- .../ErrorMessages/TailCallAttribute.fs | 32 +-- 6 files changed, 125 insertions(+), 137 deletions(-) diff --git a/src/Compiler/Checking/Expressions/CheckExpressions.fs b/src/Compiler/Checking/Expressions/CheckExpressions.fs index 5f390038e35..e2d21975311 100644 --- a/src/Compiler/Checking/Expressions/CheckExpressions.fs +++ b/src/Compiler/Checking/Expressions/CheckExpressions.fs @@ -11367,7 +11367,7 @@ and TcAttributeEx canFail (cenv: cenv) (env: TcEnv) attrTgt attrEx (synAttr: Syn if (directedTgts = AttributeTargets.Assembly || directedTgts = AttributeTargets.Module) then error(Error(FSComp.SR.tcAttributeIsNotValidForLanguageElementUseDo(), mAttr)) else - error(Error(FSComp.SR.tcAttributeIsNotValidForLanguageElement(), mAttr)) + warning(Error(FSComp.SR.tcAttributeIsNotValidForLanguageElement(), mAttr)) match ResolveObjectConstructor cenv.nameResolver env.DisplayEnv mAttr ad ty with | Exception _ when canFail = TcCanFail.IgnoreAllErrors || canFail = TcCanFail.IgnoreMemberResoutionError -> [ ], true diff --git a/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/CustomAttributes/AttributeUsage/AttributeUsage.fs b/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/CustomAttributes/AttributeUsage/AttributeUsage.fs index c7c2cf72eca..f027745b73e 100644 --- a/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/CustomAttributes/AttributeUsage/AttributeUsage.fs +++ b/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/CustomAttributes/AttributeUsage/AttributeUsage.fs @@ -104,10 +104,10 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 21, Col 21, Line 21, Col 22, "This attribute is not valid for use on this language element") - (Error 842, Line 24, Col 21, Line 24, Col 29, "This attribute is not valid for use on this language element") - (Error 842, Line 27, Col 7, Line 27, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 18, Col 7, Line 18, Col 8, "This attribute is not valid for use on this language element") + (Warning 842, Line 21, Col 21, Line 21, Col 22, "This attribute is not valid for use on this language element") + (Warning 842, Line 24, Col 21, Line 24, Col 29, "This attribute is not valid for use on this language element") + (Warning 842, Line 27, Col 7, Line 27, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 18, Col 7, Line 18, Col 8, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeTargets02.fs # E_AttributeTargets02.fs @@ -117,9 +117,10 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 14, Col 7, Line 14, Col 34, "This attribute is not valid for use on this language element") - (Error 842, Line 24, Col 7, Line 24, Col 36, "This attribute is not valid for use on this language element") - (Error 842, Line 29, Col 15, Line 29, Col 47, "This attribute is not valid for use on this language element") + (Warning 842, Line 14, Col 7, Line 14, Col 34, "This attribute is not valid for use on this language element") + (Warning 842, Line 24, Col 7, Line 24, Col 36, "This attribute is not valid for use on this language element") + (Warning 842, Line 29, Col 15, Line 29, Col 47, "This attribute is not valid for use on this language element") + (Error 3172, Line 28, Col 14, Line 28, Col 17, "A property's getter and setter must have the same type. Property 'Foo' has getter of type 'int' but setter of type 'obj'.") ] // SOURCE=E_AttributeTargetIsField01.fs # E_AttributeTargetIsField01.fs @@ -140,23 +141,23 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 9, Col 3, Line 9, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 12, Col 3, Line 12, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 15, Col 3, Line 15, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 18, Col 3, Line 18, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 21, Col 3, Line 21, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 24, Col 3, Line 24, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 27, Col 3, Line 27, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 30, Col 3, Line 30, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 33, Col 3, Line 33, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 36, Col 3, Line 36, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 39, Col 3, Line 39, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 42, Col 3, Line 42, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 45, Col 3, Line 45, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 49, Col 3, Line 49, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 56, Col 3, Line 56, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 64, Col 3, Line 64, Col 12, "This attribute is not valid for use on this language element") - (Error 842, Line 66, Col 7, Line 66, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 9, Col 3, Line 9, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 12, Col 3, Line 12, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 15, Col 3, Line 15, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 18, Col 3, Line 18, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 21, Col 3, Line 21, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 24, Col 3, Line 24, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 27, Col 3, Line 27, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 30, Col 3, Line 30, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 33, Col 3, Line 33, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 36, Col 3, Line 36, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 39, Col 3, Line 39, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 42, Col 3, Line 42, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 45, Col 3, Line 45, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 49, Col 3, Line 49, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 56, Col 3, Line 56, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 64, Col 3, Line 64, Col 12, "This attribute is not valid for use on this language element") + (Warning 842, Line 66, Col 7, Line 66, Col 16, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeTargetIsField02.fs # E_AttributeTargetIsField02.fs @@ -194,17 +195,17 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 9, Col 3, Line 9, Col 13, "This attribute is not valid for use on this language element") - (Error 842, Line 12, Col 3, Line 12, Col 13, "This attribute is not valid for use on this language element") - (Error 842, Line 15, Col 3, Line 15, Col 13, "This attribute is not valid for use on this language element") - (Error 842, Line 18, Col 3, Line 18, Col 13, "This attribute is not valid for use on this language element") - (Error 842, Line 21, Col 3, Line 21, Col 13, "This attribute is not valid for use on this language element") - (Error 842, Line 24, Col 3, Line 24, Col 13, "This attribute is not valid for use on this language element") - (Error 842, Line 26, Col 7, Line 26, Col 17, "This attribute is not valid for use on this language element") - (Error 842, Line 28, Col 3, Line 28, Col 13, "This attribute is not valid for use on this language element") - (Error 842, Line 31, Col 3, Line 31, Col 13, "This attribute is not valid for use on this language element") - (Error 842, Line 34, Col 3, Line 34, Col 13, "This attribute is not valid for use on this language element") - (Error 842, Line 39, Col 3, Line 39, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 9, Col 3, Line 9, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 12, Col 3, Line 12, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 15, Col 3, Line 15, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 18, Col 3, Line 18, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 21, Col 3, Line 21, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 24, Col 3, Line 24, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 26, Col 7, Line 26, Col 17, "This attribute is not valid for use on this language element") + (Warning 842, Line 28, Col 3, Line 28, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 31, Col 3, Line 31, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 34, Col 3, Line 34, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 39, Col 3, Line 39, Col 13, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeTargetIsMethod03.fs # E_AttributeTargetIsMethod03.fs @@ -225,21 +226,21 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 12, Col 6, Line 12, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 15, Col 6, Line 15, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 18, Col 6, Line 18, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 20, Col 10, Line 20, Col 20, "This attribute is not valid for use on this language element") - (Error 842, Line 22, Col 6, Line 22, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 25, Col 6, Line 25, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 28, Col 6, Line 28, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 31, Col 6, Line 31, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 34, Col 6, Line 34, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 37, Col 6, Line 37, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 39, Col 10, Line 39, Col 20, "This attribute is not valid for use on this language element") - (Error 842, Line 41, Col 6, Line 41, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 44, Col 6, Line 44, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 47, Col 6, Line 47, Col 16, "This attribute is not valid for use on this language element") - (Error 842, Line 52, Col 6, Line 52, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 12, Col 6, Line 12, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 15, Col 6, Line 15, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 18, Col 6, Line 18, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 20, Col 10, Line 20, Col 20, "This attribute is not valid for use on this language element") + (Warning 842, Line 22, Col 6, Line 22, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 25, Col 6, Line 25, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 28, Col 6, Line 28, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 31, Col 6, Line 31, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 34, Col 6, Line 34, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 37, Col 6, Line 37, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 39, Col 10, Line 39, Col 20, "This attribute is not valid for use on this language element") + (Warning 842, Line 41, Col 6, Line 41, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 44, Col 6, Line 44, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 47, Col 6, Line 47, Col 16, "This attribute is not valid for use on this language element") + (Warning 842, Line 52, Col 6, Line 52, Col 16, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeTargetIsMethod04.fs # E_AttributeTargetIsMethod04.fs @@ -250,8 +251,8 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 10, Col 3, Line 10, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 13, Col 3, Line 13, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 10, Col 3, Line 10, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 13, Col 3, Line 13, Col 15, "This attribute is not valid for use on this language element") ] // SOURCE=E_ConditionalAttribute.fs SCFLAGS="--test:ErrorRanges" # E_ConditionalAttribute.fs @@ -293,7 +294,7 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 12, Col 3, Line 12, Col 6, "This attribute is not valid for use on this language element") + (Warning 842, Line 12, Col 3, Line 12, Col 6, "This attribute is not valid for use on this language element") ] // SOURCE=AttributeTargetIsStruct.fs # AttributeTargetIsStruct.fs @@ -342,18 +343,18 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 13, Col 3, Line 13, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 19, Col 3, Line 19, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 22, Col 11, Line 22, Col 22, "This attribute is not valid for use on this language element") - (Error 842, Line 25, Col 3, Line 25, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 34, Col 3, Line 34, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 35, Col 3, Line 35, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 40, Col 3, Line 40, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 41, Col 3, Line 41, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 49, Col 3, Line 49, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 50, Col 3, Line 50, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 53, Col 3, Line 53, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 54, Col 3, Line 54, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 13, Col 3, Line 13, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 19, Col 3, Line 19, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 22, Col 11, Line 22, Col 22, "This attribute is not valid for use on this language element") + (Warning 842, Line 25, Col 3, Line 25, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 34, Col 3, Line 34, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 35, Col 3, Line 35, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 40, Col 3, Line 40, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 41, Col 3, Line 41, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 49, Col 3, Line 49, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 50, Col 3, Line 50, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 53, Col 3, Line 53, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 54, Col 3, Line 54, Col 18, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeTargetIsClass.fs # E_AttributeTargetIsClass.fs @@ -372,9 +373,9 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 13, Col 3, Line 13, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 19, Col 3, Line 19, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 22, Col 10, Line 22, Col 22, "This attribute is not valid for use on this language element") + (Warning 842, Line 13, Col 3, Line 13, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 19, Col 3, Line 19, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 22, Col 10, Line 22, Col 22, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeTargetIsClass01.fs # E_AttributeTargetIsClass01.fs @@ -393,8 +394,8 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 7, Col 3, Line 7, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 10, Col 10, Line 10, Col 25, "This attribute is not valid for use on this language element") + (Warning 842, Line 7, Col 3, Line 7, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 10, Col 10, Line 10, Col 25, "This attribute is not valid for use on this language element") ] // SOURCE=MarshalAsAttribute.fs # MarshalAsAttribute.fs @@ -480,7 +481,7 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 14, Col 5, Line 14, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 14, Col 5, Line 14, Col 15, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeTargetIsField03.fs # E_AttributeTargetIsField03.fs @@ -491,8 +492,8 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 14, Col 5, Line 14, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 15, Col 5, Line 15, Col 25, "This attribute is not valid for use on this language element") + (Warning 842, Line 14, Col 5, Line 14, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 15, Col 5, Line 15, Col 25, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeTargetIsProperty01.fs # E_AttributeTargetIsField03.fs @@ -511,8 +512,8 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 14, Col 5, Line 14, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 15, Col 5, Line 15, Col 25, "This attribute is not valid for use on this language element") + (Warning 842, Line 14, Col 5, Line 14, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 15, Col 5, Line 15, Col 25, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeTargetIsCtor01.fs # E_AttributeTargetIsCtor01.fs @@ -531,10 +532,10 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 9, Col 15, Line 9, Col 27, "This attribute is not valid for use on this language element") - (Error 842, Line 11, Col 16, Line 11, Col 28, "This attribute is not valid for use on this language element") - (Error 842, Line 14, Col 15, Line 14, Col 27, "This attribute is not valid for use on this language element") - (Error 842, Line 17, Col 16, Line 17, Col 28, "This attribute is not valid for use on this language element") + (Warning 842, Line 9, Col 15, Line 9, Col 27, "This attribute is not valid for use on this language element") + (Warning 842, Line 11, Col 16, Line 11, Col 28, "This attribute is not valid for use on this language element") + (Warning 842, Line 14, Col 15, Line 14, Col 27, "This attribute is not valid for use on this language element") + (Warning 842, Line 17, Col 16, Line 17, Col 28, "This attribute is not valid for use on this language element") ] // SOURCE=AttributeTargetsIsEnum01.fs # AttributeTargetsIsEnum01.fs @@ -568,10 +569,10 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 19, Col 3, Line 19, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 20, Col 3, Line 20, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 21, Col 3, Line 21, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 22, Col 3, Line 22, Col 17, "This attribute is not valid for use on this language element") + (Warning 842, Line 19, Col 3, Line 19, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 20, Col 3, Line 20, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 21, Col 3, Line 21, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 22, Col 3, Line 22, Col 17, "This attribute is not valid for use on this language element") ] // SOURCE=AttributeTargetsIsDelegate01.fs # AttributeTargetsIsDelegate01.fs @@ -605,10 +606,10 @@ module CustomAttributes_AttributeUsage = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 19, Col 3, Line 19, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 20, Col 3, Line 20, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 21, Col 3, Line 21, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 22, Col 3, Line 22, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 19, Col 3, Line 19, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 20, Col 3, Line 20, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 21, Col 3, Line 21, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 22, Col 3, Line 22, Col 13, "This attribute is not valid for use on this language element") ] [] @@ -654,10 +655,10 @@ type InterruptibleLazy<'T> private (valueFactory: unit -> 'T) = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 11, Col 3, Line 11, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 14, Col 3, Line 14, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 18, Col 3, Line 18, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 19, Col 3, Line 19, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 11, Col 3, Line 11, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 14, Col 3, Line 14, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 18, Col 3, Line 18, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 19, Col 3, Line 19, Col 15, "This attribute is not valid for use on this language element") ] // SOURCE= E_AttributeTargetIsClass02.fs # E_AttributeTargetIsClass02.fs @@ -676,18 +677,18 @@ type InterruptibleLazy<'T> private (valueFactory: unit -> 'T) = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 15, Col 3, Line 15, Col 18, "This attribute is not valid for use on this language element"); - (Error 842, Line 16, Col 3, Line 16, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 20, Col 3, Line 20, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 21, Col 3, Line 21, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 26, Col 3, Line 26, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 27, Col 3, Line 27, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 34, Col 3, Line 34, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 35, Col 3, Line 35, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 43, Col 3, Line 43, Col 18, "This attribute is not valid for use on this language element") - (Error 842, Line 44, Col 3, Line 44, Col 15, "This attribute is not valid for use on this language element") - (Error 842, Line 47, Col 3, Line 47, Col 14, "This attribute is not valid for use on this language element") - (Error 842, Line 48, Col 3, Line 48, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 15, Col 3, Line 15, Col 18, "This attribute is not valid for use on this language element"); + (Warning 842, Line 16, Col 3, Line 16, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 20, Col 3, Line 20, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 21, Col 3, Line 21, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 26, Col 3, Line 26, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 27, Col 3, Line 27, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 34, Col 3, Line 34, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 35, Col 3, Line 35, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 43, Col 3, Line 43, Col 18, "This attribute is not valid for use on this language element") + (Warning 842, Line 44, Col 3, Line 44, Col 15, "This attribute is not valid for use on this language element") + (Warning 842, Line 47, Col 3, Line 47, Col 14, "This attribute is not valid for use on this language element") + (Warning 842, Line 48, Col 3, Line 48, Col 18, "This attribute is not valid for use on this language element") ] // SOURCE= CLIMutableAttribute01.fs # CLIMutableAttribute01.fs @@ -756,8 +757,8 @@ type InterruptibleLazy<'T> private (valueFactory: unit -> 'T) = (Error 934, Line 33, Col 10, Line 33, Col 11, "Records, union, abbreviations and struct types cannot have the 'AllowNullLiteral' attribute") (Error 934, Line 36, Col 10, Line 36, Col 11, "Records, union, abbreviations and struct types cannot have the 'AllowNullLiteral' attribute") (Error 934, Line 39, Col 10, Line 39, Col 13, "Records, union, abbreviations and struct types cannot have the 'AllowNullLiteral' attribute") - (Error 842, Line 41, Col 7, Line 41, Col 23, "This attribute is not valid for use on this language element") - (Error 842, Line 44, Col 7, Line 44, Col 23, "This attribute is not valid for use on this language element") + (Warning 842, Line 41, Col 7, Line 41, Col 23, "This attribute is not valid for use on this language element") + (Warning 842, Line 44, Col 7, Line 44, Col 23, "This attribute is not valid for use on this language element") (Error 935, Line 54, Col 10, Line 54, Col 11, "Types with the 'AllowNullLiteral' attribute may only inherit from or implement types which also allow the use of the null literal") ] @@ -775,8 +776,8 @@ type InterruptibleLazy<'T> private (valueFactory: unit -> 'T) = (Error 934, Line 33, Col 10, Line 33, Col 11, "Records, union, abbreviations and struct types cannot have the 'AllowNullLiteral' attribute") (Error 934, Line 36, Col 10, Line 36, Col 11, "Records, union, abbreviations and struct types cannot have the 'AllowNullLiteral' attribute") (Error 934, Line 39, Col 10, Line 39, Col 13, "Records, union, abbreviations and struct types cannot have the 'AllowNullLiteral' attribute") - (Error 842, Line 41, Col 7, Line 41, Col 23, "This attribute is not valid for use on this language element") - (Error 842, Line 44, Col 7, Line 44, Col 23, "This attribute is not valid for use on this language element") + (Warning 842, Line 41, Col 7, Line 41, Col 23, "This attribute is not valid for use on this language element") + (Warning 842, Line 44, Col 7, Line 44, Col 23, "This attribute is not valid for use on this language element") (Error 935, Line 54, Col 10, Line 54, Col 11, "Types with the 'AllowNullLiteral' attribute may only inherit from or implement types which also allow the use of the null literal") ] diff --git a/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/CustomAttributes/Basic/Basic.fs b/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/CustomAttributes/Basic/Basic.fs index 1e3c99dc8a5..44ee388af9d 100644 --- a/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/CustomAttributes/Basic/Basic.fs +++ b/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/CustomAttributes/Basic/Basic.fs @@ -61,7 +61,7 @@ module CustomAttributes_Basic = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 15, Col 7, Line 15, Col 17, "This attribute is not valid for use on this language element") + (Warning 842, Line 15, Col 7, Line 15, Col 17, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeApplication04.fs SCFLAGS="--test:ErrorRanges" # E_AttributeApplication04.fs @@ -71,7 +71,7 @@ module CustomAttributes_Basic = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 14, Col 3, Line 14, Col 13, "This attribute is not valid for use on this language element") + (Warning 842, Line 14, Col 3, Line 14, Col 13, "This attribute is not valid for use on this language element") ] // SOURCE=E_AttributeApplication05.fs SCFLAGS="--test:ErrorRanges" # E_AttributeApplication05.fs @@ -81,7 +81,8 @@ module CustomAttributes_Basic = |> verifyCompile |> shouldFail |> withDiagnostics [ - (Error 842, Line 8, Col 7, Line 8, Col 8, "This attribute is not valid for use on this language element") + (Warning 842, Line 8, Col 7, Line 8, Col 8, "This attribute is not valid for use on this language element") + (Error 824, Line 8, Col 7, Line 8, Col 8, "Attributes are not permitted on 'let' bindings in expressions") (Warning 20, Line 8, Col 1, Line 8, Col 31, "The result of this expression has type 'int' and is implicitly ignored. Consider using 'ignore' to discard this value explicitly, e.g. 'expr |> ignore', or 'let' to bind the result to a name, e.g. 'let result = expr'.") ] diff --git a/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/EntryPoint/EntryPoint.fs b/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/EntryPoint/EntryPoint.fs index ce51bcf6c14..38b84fb6498 100644 --- a/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/EntryPoint/EntryPoint.fs +++ b/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/EntryPoint/EntryPoint.fs @@ -75,7 +75,7 @@ module EntryPoint = |> compile |> shouldFail |> withDiagnostics [ - (Error 842, Line 9, Col 3, Line 9, Col 13, """This attribute is not valid for use on this language element""") + (Warning 842, Line 9, Col 3, Line 9, Col 13, """This attribute is not valid for use on this language element""") ] // SOURCE=E_twoattributesonsamefunction001.fs SCFLAGS="--test:ErrorRanges" # E_twoattributesonsamefunction001.fs diff --git a/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/LetBindings/Basic/Basic.fs b/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/LetBindings/Basic/Basic.fs index c0a19c9ad3e..b59d28cbdd2 100644 --- a/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/LetBindings/Basic/Basic.fs +++ b/tests/FSharp.Compiler.ComponentTests/Conformance/BasicGrammarElements/LetBindings/Basic/Basic.fs @@ -53,9 +53,9 @@ module LetBindings_Basic = |> shouldFail |> withDiagnostics [ (Error 683, Line 14, Col 6, Line 14, Col 27, "Attributes are not allowed within patterns") - (Error 842, Line 14, Col 8, Line 14, Col 25, "This attribute is not valid for use on this language element") + (Warning 842, Line 14, Col 8, Line 14, Col 25, "This attribute is not valid for use on this language element") (Error 683, Line 14, Col 42, Line 14, Col 63, "Attributes are not allowed within patterns") - (Error 842, Line 14, Col 44, Line 14, Col 61, "This attribute is not valid for use on this language element") + (Warning 842, Line 14, Col 44, Line 14, Col 61, "This attribute is not valid for use on this language element") ] // SOURCE=E_ErrorsForInlineValue.fs SCFLAGS="--test:ErrorRanges" # E_ErrorsForInlineValue.fs diff --git a/tests/FSharp.Compiler.ComponentTests/ErrorMessages/TailCallAttribute.fs b/tests/FSharp.Compiler.ComponentTests/ErrorMessages/TailCallAttribute.fs index 1b68505ab1e..81ce04fc05a 100644 --- a/tests/FSharp.Compiler.ComponentTests/ErrorMessages/TailCallAttribute.fs +++ b/tests/FSharp.Compiler.ComponentTests/ErrorMessages/TailCallAttribute.fs @@ -245,7 +245,7 @@ namespace N [] let ``Warn successfully for invalid tailcalls in type methods`` () = - """ + FSharp """ namespace N module M = @@ -261,29 +261,12 @@ namespace N printfn "M2 called" this.M1() + 2 // should warn """ - |> FSharp |> withLangVersion80 |> compile |> shouldFail - |> withResults [ - { Error = Warning 3569 - Range = { StartLine = 10 - StartColumn = 17 - EndLine = 10 - EndColumn = 26 } - Message = - "The member or function 'M2' has the 'TailCallAttribute' attribute, but is not being used in a tail recursive way." } - { Error = Warning 3569 - Range = { StartLine = 15 - StartColumn = 17 - EndLine = 15 - EndColumn = 26 } - Message = -#if Debug - "The member or function 'M2' has the 'TailCallAttribute' attribute, but is not being used in a tail recursive way." } -#else - "The member or function 'M1' has the 'TailCallAttribute' attribute, but is not being used in a tail recursive way." } -#endif + |> withDiagnostics [ + (Warning 3569, Line 10, Col 17, Line 10, Col 26, "The member or function 'M2' has the 'TailCallAttribute' attribute, but is not being used in a tail recursive way."); + (Warning 3569, Line 15, Col 17, Line 15, Col 26, "The member or function 'M1' has the 'TailCallAttribute' attribute, but is not being used in a tail recursive way.") ] [] @@ -1481,7 +1464,10 @@ namespace N |> withLangVersionPreview |> compile |> shouldFail - |> withSingleDiagnostic (Error 842, Line 6, Col 11, Line 6, Col 19, "This attribute is not valid for use on this language element") + |> withDiagnostics [ + (Warning 842, Line 6, Col 11, Line 6, Col 19, "This attribute is not valid for use on this language element") + (Warning 3861, Line 7, Col 13, Line 7, Col 18, "The TailCall attribute should only be applied to recursive functions.") + ] [] let ``Error about attribute on recursive let-bound value`` () = @@ -1497,7 +1483,7 @@ namespace N |> withLangVersionPreview |> compile |> shouldFail - |> withSingleDiagnostic (Error 842, Line 6, Col 11, Line 6, Col 19, "This attribute is not valid for use on this language element") + |> withSingleDiagnostic (Warning 842, Line 6, Col 11, Line 6, Col 19, "This attribute is not valid for use on this language element") [] let ``Warn about self-defined attribute`` () = // is the analysis available for users of older FSharp.Core versions From 55507e9e7e98e640678932f96a25cb3bacc82904 Mon Sep 17 00:00:00 2001 From: Edgar Gonzalez Date: Wed, 23 Apr 2025 15:39:04 +0100 Subject: [PATCH 02/10] release notes --- docs/release-notes/.FSharp.Compiler.Service/9.0.300.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/release-notes/.FSharp.Compiler.Service/9.0.300.md b/docs/release-notes/.FSharp.Compiler.Service/9.0.300.md index 16f5721e22a..05e15a667dd 100644 --- a/docs/release-notes/.FSharp.Compiler.Service/9.0.300.md +++ b/docs/release-notes/.FSharp.Compiler.Service/9.0.300.md @@ -48,6 +48,7 @@ * Warning for "useless null handling" works with piped syntax constructs now ([PR #18331](https://github.com/dotnet/fsharp/pull/18331)) * Make indent in generated overridden member code depend on the context, not fix to 4. ([PR #18341](https://github.com/dotnet/fsharp/pull/18341)) * Adjust caller info attribute error message range ([PR #18388](https://github.com/dotnet/fsharp/pull/18388)) +* Make attribute targets mismatch a warning and not an error ([PR #18492](https://github.com/dotnet/fsharp/pull/18492)) ### Breaking Changes * Struct unions with overlapping fields now generate mappings needed for reading via reflection ([Issue #18121](https://github.com/dotnet/fsharp/issues/17797), [PR #18274](https://github.com/dotnet/fsharp/pull/17877)) From 17380183feebe6a1cf30a8f678965b6cd689de82 Mon Sep 17 00:00:00 2001 From: Edgar Gonzalez Date: Wed, 23 Apr 2025 16:19:59 +0100 Subject: [PATCH 03/10] update tests --- .../PatternMatchCompilationTests.fs | 1 + .../Language/StructActivePatternTests.fs | 2 +- tests/fsharp/typecheck/sigs/neg16.bsl | 4 +- tests/fsharp/typecheck/sigs/neg20.bsl | 46 +++++++++---------- tests/fsharp/typecheck/sigs/neg32.bsl | 2 +- .../fsharp/typecheck/sigs/version50/neg20.bsl | 46 +++++++++---------- .../UnitsOfMeasure/WithOOP/E_GenericUOM01.fs | 2 +- 7 files changed, 52 insertions(+), 51 deletions(-) diff --git a/tests/FSharp.Compiler.Service.Tests/PatternMatchCompilationTests.fs b/tests/FSharp.Compiler.Service.Tests/PatternMatchCompilationTests.fs index 1b6d54d3577..cf870698077 100644 --- a/tests/FSharp.Compiler.Service.Tests/PatternMatchCompilationTests.fs +++ b/tests/FSharp.Compiler.Service.Tests/PatternMatchCompilationTests.fs @@ -41,6 +41,7 @@ match () with dumpDiagnostics checkResults |> shouldEqual [ "(3,2--3,25): Attributes are not allowed within patterns" "(3,4--3,23): This attribute is not valid for use on this language element" + "(3,17--3,22): This is not a valid constant expression or custom attribute value" ] diff --git a/tests/fsharp/Compiler/Language/StructActivePatternTests.fs b/tests/fsharp/Compiler/Language/StructActivePatternTests.fs index aac654f549c..4c2451142fa 100644 --- a/tests/fsharp/Compiler/Language/StructActivePatternTests.fs +++ b/tests/fsharp/Compiler/Language/StructActivePatternTests.fs @@ -176,7 +176,7 @@ let (|Foo|_|) x = ValueNone [] let (|Foo|_|) x = ValueNone """ - [|(FSharpDiagnosticSeverity.Error, 842, (2, 3, 2, 9), + [|(FSharpDiagnosticSeverity.Warning, 842, (2, 3, 2, 9), "This attribute is not valid for use on this language element"); (FSharpDiagnosticSeverity.Error, 3350, (3, 6, 3, 13), "Feature 'Boolean-returning and return-type-directed partial active patterns' is not available in F# 8.0. Please use language version 9.0 or greater.")|] diff --git a/tests/fsharp/typecheck/sigs/neg16.bsl b/tests/fsharp/typecheck/sigs/neg16.bsl index 4c2300470f7..448ca9127be 100644 --- a/tests/fsharp/typecheck/sigs/neg16.bsl +++ b/tests/fsharp/typecheck/sigs/neg16.bsl @@ -13,9 +13,9 @@ neg16.fs(44,10,44,11): typecheck error FS0934: Records, union, abbreviations and neg16.fs(47,10,47,13): typecheck error FS0934: Records, union, abbreviations and struct types cannot have the 'AllowNullLiteral' attribute -neg16.fs(49,7,49,23): typecheck error FS0842: This attribute is not valid for use on this language element +neg16.fs(49,7,49,23): typecheck warning FS0842: This attribute is not valid for use on this language element -neg16.fs(52,7,52,23): typecheck error FS0842: This attribute is not valid for use on this language element +neg16.fs(52,7,52,23): typecheck warning FS0842: This attribute is not valid for use on this language element neg16.fs(59,8,59,17): typecheck error FS0001: This expression was expected to have type 'Choice<'a,'b>' diff --git a/tests/fsharp/typecheck/sigs/neg20.bsl b/tests/fsharp/typecheck/sigs/neg20.bsl index 5229dcaacf6..28fa11b53f7 100644 --- a/tests/fsharp/typecheck/sigs/neg20.bsl +++ b/tests/fsharp/typecheck/sigs/neg20.bsl @@ -213,53 +213,53 @@ neg20.fs(190,34,190,39): typecheck error FS0001: This expression was expected to but here has type 'objnull' -neg20.fs(195,5,195,10): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(195,5,195,10): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(198,5,198,11): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(198,5,198,11): typecheck warning FS0842: This attribute is not valid for use on this language element neg20.fs(202,7,202,9): typecheck error FS0825: The 'DefaultValue' attribute may only be used on 'val' declarations -neg20.fs(204,5,204,14): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(204,5,204,14): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(207,5,207,11): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(207,5,207,11): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(210,5,210,12): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(210,5,210,12): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(213,5,213,33): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(213,5,213,33): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(216,5,216,12): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(216,5,216,12): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(219,5,219,15): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(219,5,219,15): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(222,5,222,31): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(222,5,222,31): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(225,5,225,22): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(225,5,225,22): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(228,5,228,23): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(228,5,228,23): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(231,5,231,21): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(231,5,231,21): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(234,5,234,34): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(234,5,234,34): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(237,5,237,34): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(237,5,237,34): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(240,5,240,23): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(240,5,240,23): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(243,5,243,23): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(243,5,243,23): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(249,9,249,27): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(249,9,249,27): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(255,5,255,28): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(255,5,255,28): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(258,5,258,38): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(258,5,258,38): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(261,5,261,17): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(261,5,261,17): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(265,5,265,24): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(265,5,265,24): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(268,5,268,27): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(268,5,268,27): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(271,5,271,15): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(271,5,271,15): typecheck warning FS0842: This attribute is not valid for use on this language element neg20.fs(278,14,278,95): typecheck error FS0507: No accessible member or object constructor named 'ProcessStartInfo' takes 0 arguments. Note the call to this member also provides 2 named arguments. diff --git a/tests/fsharp/typecheck/sigs/neg32.bsl b/tests/fsharp/typecheck/sigs/neg32.bsl index 87fbc723312..376138c1858 100644 --- a/tests/fsharp/typecheck/sigs/neg32.bsl +++ b/tests/fsharp/typecheck/sigs/neg32.bsl @@ -1,5 +1,5 @@ -neg32.fs(17,11,17,56): typecheck error FS0842: This attribute is not valid for use on this language element +neg32.fs(17,11,17,56): typecheck warning FS0842: This attribute is not valid for use on this language element neg32.fs(24,15,24,16): typecheck error FS0043: The member or object constructor 'TryParse' does not take 1 argument(s). An overload was found taking 2 arguments. diff --git a/tests/fsharp/typecheck/sigs/version50/neg20.bsl b/tests/fsharp/typecheck/sigs/version50/neg20.bsl index 394f7777b2a..f85f1d5d14f 100644 --- a/tests/fsharp/typecheck/sigs/version50/neg20.bsl +++ b/tests/fsharp/typecheck/sigs/version50/neg20.bsl @@ -261,53 +261,53 @@ neg20.fs(190,34,190,39): typecheck error FS0001: This expression was expected to but here has type 'objnull' -neg20.fs(195,5,195,10): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(195,5,195,10): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(198,5,198,11): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(198,5,198,11): typecheck warning FS0842: This attribute is not valid for use on this language element neg20.fs(202,7,202,9): typecheck error FS0825: The 'DefaultValue' attribute may only be used on 'val' declarations -neg20.fs(204,5,204,14): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(204,5,204,14): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(207,5,207,11): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(207,5,207,11): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(210,5,210,12): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(210,5,210,12): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(213,5,213,33): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(213,5,213,33): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(216,5,216,12): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(216,5,216,12): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(219,5,219,15): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(219,5,219,15): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(222,5,222,31): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(222,5,222,31): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(225,5,225,22): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(225,5,225,22): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(228,5,228,23): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(228,5,228,23): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(231,5,231,21): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(231,5,231,21): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(234,5,234,34): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(234,5,234,34): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(237,5,237,34): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(237,5,237,34): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(240,5,240,23): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(240,5,240,23): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(243,5,243,23): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(243,5,243,23): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(249,9,249,27): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(249,9,249,27): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(255,5,255,28): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(255,5,255,28): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(258,5,258,38): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(258,5,258,38): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(261,5,261,17): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(261,5,261,17): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(265,5,265,24): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(265,5,265,24): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(268,5,268,27): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(268,5,268,27): typecheck warning FS0842: This attribute is not valid for use on this language element -neg20.fs(271,5,271,15): typecheck error FS0842: This attribute is not valid for use on this language element +neg20.fs(271,5,271,15): typecheck warning FS0842: This attribute is not valid for use on this language element neg20.fs(278,14,278,95): typecheck error FS0507: No accessible member or object constructor named 'ProcessStartInfo' takes 0 arguments. Note the call to this member also provides 2 named arguments. diff --git a/tests/fsharpqa/Source/Conformance/UnitsOfMeasure/WithOOP/E_GenericUOM01.fs b/tests/fsharpqa/Source/Conformance/UnitsOfMeasure/WithOOP/E_GenericUOM01.fs index 369697935e3..0f27193b5a7 100644 --- a/tests/fsharpqa/Source/Conformance/UnitsOfMeasure/WithOOP/E_GenericUOM01.fs +++ b/tests/fsharpqa/Source/Conformance/UnitsOfMeasure/WithOOP/E_GenericUOM01.fs @@ -1,7 +1,7 @@ // #Regression #Conformance #UnitsOfMeasure #ObjectOrientedTypes // Verify error when putting invalid attributes on type arguments // (We should only allow [].) -//This attribute is not valid for use on this language element +//This attribute is not valid for use on this language element open System From 6f2b7064781a2c33c254f17ffac1a31a8cd3f41e Mon Sep 17 00:00:00 2001 From: edgargonzalez Date: Tue, 29 Apr 2025 09:43:56 +0100 Subject: [PATCH 04/10] update baselines --- tests/fsharp/typecheck/sigs/neg16.bsl | 4 +- tests/fsharp/typecheck/sigs/neg20.bsl | 48 ++++++++++--------- tests/fsharp/typecheck/sigs/neg32.bsl | 4 +- .../fsharp/typecheck/sigs/version50/neg20.bsl | 48 ++++++++++--------- 4 files changed, 54 insertions(+), 50 deletions(-) diff --git a/tests/fsharp/typecheck/sigs/neg16.bsl b/tests/fsharp/typecheck/sigs/neg16.bsl index 448ca9127be..4c2300470f7 100644 --- a/tests/fsharp/typecheck/sigs/neg16.bsl +++ b/tests/fsharp/typecheck/sigs/neg16.bsl @@ -13,9 +13,9 @@ neg16.fs(44,10,44,11): typecheck error FS0934: Records, union, abbreviations and neg16.fs(47,10,47,13): typecheck error FS0934: Records, union, abbreviations and struct types cannot have the 'AllowNullLiteral' attribute -neg16.fs(49,7,49,23): typecheck warning FS0842: This attribute is not valid for use on this language element +neg16.fs(49,7,49,23): typecheck error FS0842: This attribute is not valid for use on this language element -neg16.fs(52,7,52,23): typecheck warning FS0842: This attribute is not valid for use on this language element +neg16.fs(52,7,52,23): typecheck error FS0842: This attribute is not valid for use on this language element neg16.fs(59,8,59,17): typecheck error FS0001: This expression was expected to have type 'Choice<'a,'b>' diff --git a/tests/fsharp/typecheck/sigs/neg20.bsl b/tests/fsharp/typecheck/sigs/neg20.bsl index 28fa11b53f7..2ff8515a78a 100644 --- a/tests/fsharp/typecheck/sigs/neg20.bsl +++ b/tests/fsharp/typecheck/sigs/neg20.bsl @@ -213,53 +213,53 @@ neg20.fs(190,34,190,39): typecheck error FS0001: This expression was expected to but here has type 'objnull' -neg20.fs(195,5,195,10): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(195,5,195,10): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(198,5,198,11): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(198,5,198,11): typecheck error FS0842: This attribute is not valid for use on this language element neg20.fs(202,7,202,9): typecheck error FS0825: The 'DefaultValue' attribute may only be used on 'val' declarations -neg20.fs(204,5,204,14): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(204,5,204,14): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(207,5,207,11): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(207,5,207,11): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(210,5,210,12): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(210,5,210,12): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(213,5,213,33): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(213,5,213,33): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(216,5,216,12): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(216,5,216,12): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(219,5,219,15): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(219,5,219,15): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(222,5,222,31): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(222,5,222,31): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(225,5,225,22): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(225,5,225,22): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(228,5,228,23): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(228,5,228,23): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(231,5,231,21): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(231,5,231,21): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(234,5,234,34): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(234,5,234,34): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(237,5,237,34): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(237,5,237,34): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(240,5,240,23): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(240,5,240,23): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(243,5,243,23): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(243,5,243,23): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(249,9,249,27): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(249,9,249,27): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(255,5,255,28): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(255,5,255,28): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(258,5,258,38): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(258,5,258,38): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(261,5,261,17): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(261,5,261,17): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(265,5,265,24): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(265,5,265,24): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(268,5,268,27): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(268,5,268,27): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(271,5,271,15): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(271,5,271,15): typecheck error FS0842: This attribute is not valid for use on this language element neg20.fs(278,14,278,95): typecheck error FS0507: No accessible member or object constructor named 'ProcessStartInfo' takes 0 arguments. Note the call to this member also provides 2 named arguments. @@ -294,6 +294,7 @@ neg20.fs(335,11,335,24): typecheck error FS0041: A unique overload for method 'S Known type of argument: 'a0 Candidates: + - System.String(value: System.ReadOnlySpan) : System.String - System.String(value: char array) : System.String - System.String(value: nativeptr) : System.String - System.String(value: nativeptr) : System.String @@ -303,6 +304,7 @@ neg20.fs(336,11,336,22): typecheck error FS0041: A unique overload for method 'G Known type of argument: 'a0 Candidates: + - System.Guid(b: System.ReadOnlySpan) : System.Guid - System.Guid(b: byte array) : System.Guid - System.Guid(g: string) : System.Guid diff --git a/tests/fsharp/typecheck/sigs/neg32.bsl b/tests/fsharp/typecheck/sigs/neg32.bsl index 376138c1858..7649c0719b5 100644 --- a/tests/fsharp/typecheck/sigs/neg32.bsl +++ b/tests/fsharp/typecheck/sigs/neg32.bsl @@ -1,7 +1,7 @@ -neg32.fs(17,11,17,56): typecheck warning FS0842: This attribute is not valid for use on this language element +neg32.fs(17,11,17,56): typecheck error FS0842: This attribute is not valid for use on this language element -neg32.fs(24,15,24,16): typecheck error FS0043: The member or object constructor 'TryParse' does not take 1 argument(s). An overload was found taking 2 arguments. +neg32.fs(24,15,24,16): typecheck error FS0043: The member or object constructor 'TryParse' does not take 1 argument(s). An overload was found taking 4 arguments. neg32.fs(43,17,43,19): typecheck error FS0039: The type parameter 'T is not defined. diff --git a/tests/fsharp/typecheck/sigs/version50/neg20.bsl b/tests/fsharp/typecheck/sigs/version50/neg20.bsl index f85f1d5d14f..d5de8268fab 100644 --- a/tests/fsharp/typecheck/sigs/version50/neg20.bsl +++ b/tests/fsharp/typecheck/sigs/version50/neg20.bsl @@ -261,53 +261,53 @@ neg20.fs(190,34,190,39): typecheck error FS0001: This expression was expected to but here has type 'objnull' -neg20.fs(195,5,195,10): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(195,5,195,10): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(198,5,198,11): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(198,5,198,11): typecheck error FS0842: This attribute is not valid for use on this language element neg20.fs(202,7,202,9): typecheck error FS0825: The 'DefaultValue' attribute may only be used on 'val' declarations -neg20.fs(204,5,204,14): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(204,5,204,14): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(207,5,207,11): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(207,5,207,11): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(210,5,210,12): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(210,5,210,12): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(213,5,213,33): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(213,5,213,33): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(216,5,216,12): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(216,5,216,12): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(219,5,219,15): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(219,5,219,15): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(222,5,222,31): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(222,5,222,31): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(225,5,225,22): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(225,5,225,22): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(228,5,228,23): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(228,5,228,23): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(231,5,231,21): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(231,5,231,21): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(234,5,234,34): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(234,5,234,34): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(237,5,237,34): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(237,5,237,34): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(240,5,240,23): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(240,5,240,23): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(243,5,243,23): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(243,5,243,23): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(249,9,249,27): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(249,9,249,27): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(255,5,255,28): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(255,5,255,28): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(258,5,258,38): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(258,5,258,38): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(261,5,261,17): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(261,5,261,17): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(265,5,265,24): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(265,5,265,24): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(268,5,268,27): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(268,5,268,27): typecheck error FS0842: This attribute is not valid for use on this language element -neg20.fs(271,5,271,15): typecheck warning FS0842: This attribute is not valid for use on this language element +neg20.fs(271,5,271,15): typecheck error FS0842: This attribute is not valid for use on this language element neg20.fs(278,14,278,95): typecheck error FS0507: No accessible member or object constructor named 'ProcessStartInfo' takes 0 arguments. Note the call to this member also provides 2 named arguments. @@ -342,6 +342,7 @@ neg20.fs(335,11,335,24): typecheck error FS0041: A unique overload for method 'S Known type of argument: 'a0 Candidates: + - System.String(value: System.ReadOnlySpan) : System.String - System.String(value: char array) : System.String - System.String(value: nativeptr) : System.String - System.String(value: nativeptr) : System.String @@ -351,6 +352,7 @@ neg20.fs(336,11,336,22): typecheck error FS0041: A unique overload for method 'G Known type of argument: 'a0 Candidates: + - System.Guid(b: System.ReadOnlySpan) : System.Guid - System.Guid(b: byte array) : System.Guid - System.Guid(g: string) : System.Guid From 75d8f5ef637741991df6c15ae75d202b8412dd65 Mon Sep 17 00:00:00 2001 From: edgargonzalez Date: Tue, 29 Apr 2025 19:33:38 +0100 Subject: [PATCH 05/10] Update baselines --- tests/fsharp/typecheck/sigs/neg20.bsl | 2 -- tests/fsharp/typecheck/sigs/neg32.bsl | 2 +- tests/fsharp/typecheck/sigs/version50/neg20.bsl | 2 -- 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/tests/fsharp/typecheck/sigs/neg20.bsl b/tests/fsharp/typecheck/sigs/neg20.bsl index 2ff8515a78a..5229dcaacf6 100644 --- a/tests/fsharp/typecheck/sigs/neg20.bsl +++ b/tests/fsharp/typecheck/sigs/neg20.bsl @@ -294,7 +294,6 @@ neg20.fs(335,11,335,24): typecheck error FS0041: A unique overload for method 'S Known type of argument: 'a0 Candidates: - - System.String(value: System.ReadOnlySpan) : System.String - System.String(value: char array) : System.String - System.String(value: nativeptr) : System.String - System.String(value: nativeptr) : System.String @@ -304,7 +303,6 @@ neg20.fs(336,11,336,22): typecheck error FS0041: A unique overload for method 'G Known type of argument: 'a0 Candidates: - - System.Guid(b: System.ReadOnlySpan) : System.Guid - System.Guid(b: byte array) : System.Guid - System.Guid(g: string) : System.Guid diff --git a/tests/fsharp/typecheck/sigs/neg32.bsl b/tests/fsharp/typecheck/sigs/neg32.bsl index 7649c0719b5..87fbc723312 100644 --- a/tests/fsharp/typecheck/sigs/neg32.bsl +++ b/tests/fsharp/typecheck/sigs/neg32.bsl @@ -1,7 +1,7 @@ neg32.fs(17,11,17,56): typecheck error FS0842: This attribute is not valid for use on this language element -neg32.fs(24,15,24,16): typecheck error FS0043: The member or object constructor 'TryParse' does not take 1 argument(s). An overload was found taking 4 arguments. +neg32.fs(24,15,24,16): typecheck error FS0043: The member or object constructor 'TryParse' does not take 1 argument(s). An overload was found taking 2 arguments. neg32.fs(43,17,43,19): typecheck error FS0039: The type parameter 'T is not defined. diff --git a/tests/fsharp/typecheck/sigs/version50/neg20.bsl b/tests/fsharp/typecheck/sigs/version50/neg20.bsl index d5de8268fab..394f7777b2a 100644 --- a/tests/fsharp/typecheck/sigs/version50/neg20.bsl +++ b/tests/fsharp/typecheck/sigs/version50/neg20.bsl @@ -342,7 +342,6 @@ neg20.fs(335,11,335,24): typecheck error FS0041: A unique overload for method 'S Known type of argument: 'a0 Candidates: - - System.String(value: System.ReadOnlySpan) : System.String - System.String(value: char array) : System.String - System.String(value: nativeptr) : System.String - System.String(value: nativeptr) : System.String @@ -352,7 +351,6 @@ neg20.fs(336,11,336,22): typecheck error FS0041: A unique overload for method 'G Known type of argument: 'a0 Candidates: - - System.Guid(b: System.ReadOnlySpan) : System.Guid - System.Guid(b: byte array) : System.Guid - System.Guid(g: string) : System.Guid From 4248f2a9225b2533cb4137d1e1b4311ce9e3cad1 Mon Sep 17 00:00:00 2001 From: Edgar Gonzalez Date: Wed, 30 Apr 2025 21:58:10 +0100 Subject: [PATCH 06/10] Move attribute form logic to an AP --- .../Checking/Expressions/CheckExpressions.fs | 55 +++++++++++-------- 1 file changed, 32 insertions(+), 23 deletions(-) diff --git a/src/Compiler/Checking/Expressions/CheckExpressions.fs b/src/Compiler/Checking/Expressions/CheckExpressions.fs index e2d21975311..567e1da0310 100644 --- a/src/Compiler/Checking/Expressions/CheckExpressions.fs +++ b/src/Compiler/Checking/Expressions/CheckExpressions.fs @@ -3187,6 +3187,24 @@ let BuildRecdFieldSet g m objExpr (rfinfo: RecdFieldInfo) argExpr = let wrap, objExpr, _readonly, _writeonly = mkExprAddrOfExpr g boxity false DefinitelyMutates objExpr None m wrap (mkRecdFieldSetViaExprAddr (objExpr, rfinfo.RecdFieldRef, rfinfo.TypeInst, argExpr, m) ) +// This is used to check the target of an attribute with the form of +// Long Form: [] +// Short Form: [] +let (|LongFormAttrTarget|UnrecognizedLongAttrTarget|ShortFormAttributeTarget|) (targetIndicator: Ident option) = + match targetIndicator with + | Some id when id.idText = "assembly" -> LongFormAttrTarget AttributeTargets.Assembly + | Some id when id.idText = "module" -> LongFormAttrTarget AttributeTargets.Module + | Some id when id.idText = "return" -> LongFormAttrTarget AttributeTargets.ReturnValue + | Some id when id.idText = "field" -> LongFormAttrTarget AttributeTargets.Field + | Some id when id.idText = "property" -> LongFormAttrTarget AttributeTargets.Property + | Some id when id.idText = "method" -> LongFormAttrTarget AttributeTargets.Method + | Some id when id.idText = "param" -> LongFormAttrTarget AttributeTargets.Parameter + | Some id when id.idText = "type" -> LongFormAttrTarget AttributeTargets.TyconDecl + | Some id when id.idText = "constructor" -> LongFormAttrTarget AttributeTargets.Constructor + | Some id when id.idText = "event" -> LongFormAttrTarget AttributeTargets.Event + | Some id -> UnrecognizedLongAttrTarget id + | None -> ShortFormAttributeTarget + //------------------------------------------------------------------------- // Helpers dealing with named and optional args at callsites //------------------------------------------------------------------------- @@ -11344,27 +11362,18 @@ and TcAttributeEx canFail (cenv: cenv) (env: TcEnv) attrTgt attrEx (synAttr: Syn (validOnDefault, inheritedDefault) | _ -> (validOnDefault, inheritedDefault) - let possibleTgts = enum validOn &&& attrTgt - let directedTgts = + let attributeTargets = enum validOn &&& attrTgt + let directedTargets = match targetIndicator with - | Some id when id.idText = "assembly" -> AttributeTargets.Assembly - | Some id when id.idText = "module" -> AttributeTargets.Module - | Some id when id.idText = "return" -> AttributeTargets.ReturnValue - | Some id when id.idText = "field" -> AttributeTargets.Field - | Some id when id.idText = "property" -> AttributeTargets.Property - | Some id when id.idText = "method" -> AttributeTargets.Method - | Some id when id.idText = "param" -> AttributeTargets.Parameter - | Some id when id.idText = "type" -> AttributeTargets.TyconDecl - | Some id when id.idText = "constructor" -> AttributeTargets.Constructor - | Some id when id.idText = "event" -> AttributeTargets.Event - | Some id -> - errorR(Error(FSComp.SR.tcUnrecognizedAttributeTarget(), id.idRange)) - possibleTgts - // mask explicit targets - | _ -> possibleTgts &&& ~~~ attrEx - let constrainedTgts = possibleTgts &&& directedTgts - if constrainedTgts = enum 0 then - if (directedTgts = AttributeTargets.Assembly || directedTgts = AttributeTargets.Module) then + | LongFormAttrTarget attrTarget -> attrTarget + | UnrecognizedLongAttrTarget attrTarget -> + errorR(Error(FSComp.SR.tcUnrecognizedAttributeTarget(), attrTarget.idRange)) + attributeTargets + | ShortFormAttributeTarget -> attributeTargets &&& ~~~ attrEx + + let constrainedTargets = attributeTargets &&& directedTargets + if constrainedTargets = enum 0 then + if (directedTargets = AttributeTargets.Assembly || directedTargets = AttributeTargets.Module) then error(Error(FSComp.SR.tcAttributeIsNotValidForLanguageElementUseDo(), mAttr)) else warning(Error(FSComp.SR.tcAttributeIsNotValidForLanguageElement(), mAttr)) @@ -11428,11 +11437,11 @@ and TcAttributeEx canFail (cenv: cenv) (env: TcEnv) attrTgt attrEx (synAttr: Syn if isStruct then error (Error(FSComp.SR.tcCustomAttributeMustBeReferenceType(), m)) if args.Length <> ilMethRef.ArgTypes.Length then error (Error(FSComp.SR.tcCustomAttributeArgumentMismatch(), m)) let args = args |> List.map mkAttribExpr - Attrib(tcref, ILAttrib ilMethRef, args, namedAttribArgMap, isAppliedToGetterOrSetter, Some constrainedTgts, m) + Attrib(tcref, ILAttrib ilMethRef, args, namedAttribArgMap, isAppliedToGetterOrSetter, Some constrainedTargets, m) | Expr.App (InnerExprPat(ExprValWithPossibleTypeInst(vref, _, _, _)), _, _, args, _) -> let args = args |> List.collect (function Expr.Const (Const.Unit, _, _) -> [] | expr -> tryDestRefTupleExpr expr) |> List.map mkAttribExpr - Attrib(tcref, FSAttrib vref, args, namedAttribArgMap, isAppliedToGetterOrSetter, Some constrainedTgts, mAttr) + Attrib(tcref, FSAttrib vref, args, namedAttribArgMap, isAppliedToGetterOrSetter, Some constrainedTargets, mAttr) | _ -> error (Error(FSComp.SR.tcCustomAttributeMustInvokeConstructor(), mAttr)) @@ -11440,7 +11449,7 @@ and TcAttributeEx canFail (cenv: cenv) (env: TcEnv) attrTgt attrEx (synAttr: Syn | _ -> error(Error(FSComp.SR.tcAttributeExpressionsMustBeConstructorCalls(), mAttr)) - [ (constrainedTgts, attrib) ], false + [ (constrainedTargets, attrib) ], false and TcAttributesWithPossibleTargetsEx canFail (cenv: cenv) env attrTgt attrEx synAttribs = From 07415ea7492149b82b13796ea2a849706b8ff636 Mon Sep 17 00:00:00 2001 From: edgargonzalez Date: Sat, 2 Aug 2025 09:06:32 +0200 Subject: [PATCH 07/10] Unify `SynExprLetOrUse` trivia --- .../Expressions/CheckComputationExpressions.fs | 16 ++++++++-------- .../Checking/Expressions/CheckExpressions.fs | 2 +- src/Compiler/SyntaxTree/ParseHelpers.fs | 11 +++++++++-- src/Compiler/SyntaxTree/SyntaxTree.fs | 2 +- src/Compiler/SyntaxTree/SyntaxTree.fsi | 2 +- src/Compiler/SyntaxTree/SyntaxTrivia.fs | 13 +------------ src/Compiler/SyntaxTree/SyntaxTrivia.fsi | 12 +----------- ...eThatStartsAtAndAndEndsAfterExpression.fs.bsl | 3 ++- ...RangeStartsAtAndAndEndsAfterExpression.fs.bsl | 3 ++- ...xprLetOrUseContainsTheRangeOfInKeyword.fs.bsl | 6 ++++-- ...UseBangContainsTheRangeOfTheEqualsSign.fs.bsl | 3 ++- ...xprLetOrUseContainsTheRangeOfInKeyword.fs.bsl | 3 ++- ...OrUseDoesNotContainTheRangeOfInKeyword.fs.bsl | 3 ++- ...ctersDoesNotContainTheRangeOfInKeyword.fs.bsl | 3 ++- ...siveBindingContainsTheRangeOfInKeyword.fs.bsl | 12 +++++++----- .../Expression/Try with - Missing expr 04.fs.bsl | 13 +++++++------ .../SyntaxTree/SynType/Typed LetBang 01.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 02.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 03.fs.bsl | 8 +++++--- .../SyntaxTree/SynType/Typed LetBang 04.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 05.fs.bsl | 6 ++++-- .../SyntaxTree/SynType/Typed LetBang 06.fs.bsl | 6 ++++-- .../SyntaxTree/SynType/Typed LetBang 07.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 08.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 09.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 10.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 11.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 12.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 14.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 15.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 17.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 18.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 19.fs.bsl | 8 +++++--- .../SyntaxTree/SynType/Typed LetBang 20.fs.bsl | 8 +++++--- .../SynType/Typed LetBang AndBang 01.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 02.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 03.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 04.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 05.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 06.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 07.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 08.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 09.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 10.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 11.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 12.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 13.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 14.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 15.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 16.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 17.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 18.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed UseBang 01.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed UseBang 02.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed UseBang 03.fs.bsl | 6 ++++-- .../SyntaxTree/SynType/Typed UseBang 04.fs.bsl | 6 ++++-- .../SyntaxTree/SynType/Typed UseBang 05.fs.bsl | 3 ++- 57 files changed, 151 insertions(+), 106 deletions(-) diff --git a/src/Compiler/Checking/Expressions/CheckComputationExpressions.fs b/src/Compiler/Checking/Expressions/CheckComputationExpressions.fs index 00b992a6f92..3258dbbb9a5 100644 --- a/src/Compiler/Checking/Expressions/CheckComputationExpressions.fs +++ b/src/Compiler/Checking/Expressions/CheckComputationExpressions.fs @@ -861,7 +861,7 @@ let (|ExprAsUseBang|_|) expr = rhs = rhsExpr andBangs = andBangs body = innerComp - trivia = { LetOrUseBangKeyword = mBind }) -> ValueSome(spBind, isFromSource, pat, rhsExpr, andBangs, innerComp, mBind) + trivia = { LetOrUseKeyword = mBind }) -> ValueSome(spBind, isFromSource, pat, rhsExpr, andBangs, innerComp, mBind) | _ -> ValueNone [] @@ -875,7 +875,7 @@ let (|ExprAsLetBang|_|) expr = rhs = letRhsExpr andBangs = andBangBindings body = innerComp - trivia = { LetOrUseBangKeyword = mBind }) -> ValueSome(spBind, isFromSource, letPat, letRhsExpr, andBangBindings, innerComp, mBind) + trivia = { LetOrUseKeyword = mBind }) -> ValueSome(spBind, isFromSource, letPat, letRhsExpr, andBangBindings, innerComp, mBind) | _ -> ValueNone // "cexpr; cexpr" is treated as builder.Combine(cexpr1, cexpr1) @@ -1393,7 +1393,7 @@ let rec TryTranslateComputationExpression [], setCondExpr, mGuard, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) let whileExpr = @@ -1422,7 +1422,7 @@ let rec TryTranslateComputationExpression [], body, mGuard, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) TryTranslateComputationExpression ceenv CompExprTranslationPass.Initial q varSpace rewrittenWhileExpr translatedCtxt @@ -1637,7 +1637,7 @@ let rec TryTranslateComputationExpression [], innerComp2, m, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero )) translatedCtxt ) @@ -2393,7 +2393,7 @@ and ConsumeCustomOpClauses [], contExpr, intoPat.Range, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) else SynExpr.ForEach( @@ -2434,7 +2434,7 @@ and ConsumeCustomOpClauses [], compClausesExpr, compClausesExpr.Range, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) else SynExpr.ForEach( @@ -2697,7 +2697,7 @@ and TranslateComputationExpression (ceenv: ComputationExpressionContext<'a>) fir [], bodyExpr, m, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) TranslateComputationExpression ceenv CompExprTranslationPass.Initial q varSpace letBangBind translatedCtxt diff --git a/src/Compiler/Checking/Expressions/CheckExpressions.fs b/src/Compiler/Checking/Expressions/CheckExpressions.fs index 5862b907e05..1d191d77fd7 100644 --- a/src/Compiler/Checking/Expressions/CheckExpressions.fs +++ b/src/Compiler/Checking/Expressions/CheckExpressions.fs @@ -6072,7 +6072,7 @@ and TcExprUndelayed (cenv: cenv) (overallTy: OverallTy) env tpenv (synExpr: SynE | SynExpr.DoBang (trivia = { DoBangKeyword = m }) | SynExpr.MatchBang (trivia = { MatchBangKeyword = m }) | SynExpr.WhileBang (range = m) - | SynExpr.LetOrUseBang (trivia = { LetOrUseBangKeyword = m }) -> + | SynExpr.LetOrUseBang (trivia = { LetOrUseKeyword = m }) -> error(Error(FSComp.SR.tcConstructRequiresComputationExpression(), m)) | SynExpr.IndexFromEnd (rightExpr, m) -> diff --git a/src/Compiler/SyntaxTree/ParseHelpers.fs b/src/Compiler/SyntaxTree/ParseHelpers.fs index 4aeffc3a056..b9c409525dd 100644 --- a/src/Compiler/SyntaxTree/ParseHelpers.fs +++ b/src/Compiler/SyntaxTree/ParseHelpers.fs @@ -1071,9 +1071,10 @@ let mkLetExpression // Create let! or use! expression let spBind = DebugPointAtBinding.Yes(unionRanges mKeyword rhs.Range) - let trivia: SynExprLetOrUseBangTrivia = + let trivia: SynExprLetOrUseTrivia = { - LetOrUseBangKeyword = mKeyword + LetOrUseKeyword = mKeyword + InKeyword = mIn EqualsRange = mEquals } // isFromSource is true for user-written code @@ -1105,6 +1106,11 @@ let mkLetExpression match decls with | SynBinding(trivia = trivia) :: _ -> trivia.LeadingKeyword.Range | _ -> range0 + + let mEquals = + match decls with + | SynBinding(trivia = trivia) :: _ -> trivia.EqualsRange + | _ -> None SynExpr.LetOrUse( isRec, @@ -1115,6 +1121,7 @@ let mkLetExpression { LetOrUseKeyword = mLetOrUse InKeyword = mIn' + EqualsRange = mEquals } ) | None -> SynExpr.FromParseError(body, mWhole) diff --git a/src/Compiler/SyntaxTree/SyntaxTree.fs b/src/Compiler/SyntaxTree/SyntaxTree.fs index 5e3542f6b69..acbb6d0a26e 100644 --- a/src/Compiler/SyntaxTree/SyntaxTree.fs +++ b/src/Compiler/SyntaxTree/SyntaxTree.fs @@ -729,7 +729,7 @@ type SynExpr = andBangs: SynExprAndBang list * body: SynExpr * range: range * - trivia: SynExprLetOrUseBangTrivia + trivia: SynExprLetOrUseTrivia | MatchBang of matchDebugPoint: DebugPointAtBinding * diff --git a/src/Compiler/SyntaxTree/SyntaxTree.fsi b/src/Compiler/SyntaxTree/SyntaxTree.fsi index aa6f394d6c4..2dd3bb35aae 100644 --- a/src/Compiler/SyntaxTree/SyntaxTree.fsi +++ b/src/Compiler/SyntaxTree/SyntaxTree.fsi @@ -899,7 +899,7 @@ type SynExpr = andBangs: SynExprAndBang list * body: SynExpr * range: range * - trivia: SynExprLetOrUseBangTrivia + trivia: SynExprLetOrUseTrivia /// F# syntax: match! expr with pat1 -> expr | ... | patN -> exprN | MatchBang of diff --git a/src/Compiler/SyntaxTree/SyntaxTrivia.fs b/src/Compiler/SyntaxTree/SyntaxTrivia.fs index 56002949b5c..7befe5e4a01 100644 --- a/src/Compiler/SyntaxTree/SyntaxTrivia.fs +++ b/src/Compiler/SyntaxTree/SyntaxTrivia.fs @@ -94,24 +94,13 @@ type SynExprLetOrUseTrivia = { LetOrUseKeyword: range InKeyword: range option + EqualsRange: range option } static member Zero: SynExprLetOrUseTrivia = { InKeyword = None LetOrUseKeyword = range0 - } - -[] -type SynExprLetOrUseBangTrivia = - { - LetOrUseBangKeyword: range - EqualsRange: range option - } - - static member Zero: SynExprLetOrUseBangTrivia = - { - LetOrUseBangKeyword = range0 EqualsRange = None } diff --git a/src/Compiler/SyntaxTree/SyntaxTrivia.fsi b/src/Compiler/SyntaxTree/SyntaxTrivia.fsi index 89d7124e5f1..9a0b8d6b363 100644 --- a/src/Compiler/SyntaxTree/SyntaxTrivia.fsi +++ b/src/Compiler/SyntaxTree/SyntaxTrivia.fsi @@ -132,21 +132,11 @@ type SynExprLetOrUseTrivia = LetOrUseKeyword: range /// The syntax range of the `in` keyword. InKeyword: range option - } - - static member Zero: SynExprLetOrUseTrivia -/// Represents additional information for SynExpr.LetOrUseBang -[] -type SynExprLetOrUseBangTrivia = - { - /// The syntax range of the `let!` or `use!` keyword. - LetOrUseBangKeyword: range - /// The syntax range of the `=` token. EqualsRange: range option } - static member Zero: SynExprLetOrUseBangTrivia + static member Zero: SynExprLetOrUseTrivia /// Represents additional information for SynExpr.Match [] diff --git a/tests/service/data/SyntaxTree/ComputationExpression/MultipleSynExprAndBangHaveRangeThatStartsAtAndAndEndsAfterExpression.fs.bsl b/tests/service/data/SyntaxTree/ComputationExpression/MultipleSynExprAndBangHaveRangeThatStartsAtAndAndEndsAfterExpression.fs.bsl index a9f281321fa..bdee1f621ed 100644 --- a/tests/service/data/SyntaxTree/ComputationExpression/MultipleSynExprAndBangHaveRangeThatStartsAtAndAndEndsAfterExpression.fs.bsl +++ b/tests/service/data/SyntaxTree/ComputationExpression/MultipleSynExprAndBangHaveRangeThatStartsAtAndAndEndsAfterExpression.fs.bsl @@ -41,7 +41,8 @@ ImplFile YieldOrReturn ((false, true), Ident bar, (6,4--6,14), { YieldOrReturnKeyword = (6,4--6,10) }), (3,4--6,14), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,13--3,14) }), (2,6--7,1)), (2,0--7,1)), (2,0--7,1))], PreXmlDocEmpty, [], None, (2,0--7,1), { LeadingKeyword = None })], (true, true), diff --git a/tests/service/data/SyntaxTree/ComputationExpression/SynExprAndBangRangeStartsAtAndAndEndsAfterExpression.fs.bsl b/tests/service/data/SyntaxTree/ComputationExpression/SynExprAndBangRangeStartsAtAndAndEndsAfterExpression.fs.bsl index 031ace760eb..58d455dacb1 100644 --- a/tests/service/data/SyntaxTree/ComputationExpression/SynExprAndBangRangeStartsAtAndAndEndsAfterExpression.fs.bsl +++ b/tests/service/data/SyntaxTree/ComputationExpression/SynExprAndBangRangeStartsAtAndAndEndsAfterExpression.fs.bsl @@ -31,7 +31,8 @@ ImplFile YieldOrReturn ((false, true), Ident bar, (7,4--7,14), { YieldOrReturnKeyword = (7,4--7,10) }), (3,4--7,14), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,13--3,14) }), (2,6--8,1)), (2,0--8,1)), (2,0--8,1))], PreXmlDocEmpty, [], None, (2,0--8,1), { LeadingKeyword = None })], (true, true), diff --git a/tests/service/data/SyntaxTree/Expression/NestedSynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/NestedSynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl index 51a31c623dd..fc36bd59dfc 100644 --- a/tests/service/data/SyntaxTree/Expression/NestedSynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/NestedSynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl @@ -55,9 +55,11 @@ ImplFile (5,6--5,7)), Ident x, (5,4--5,7)), Ident y, (5,4--5,9)), (4,4--5,9), { LetOrUseKeyword = (4,4--4,7) - InKeyword = Some (4,14--4,16) }), (3,4--5,9), + InKeyword = Some (4,14--4,16) + EqualsRange = Some (4,10--4,11) }), (3,4--5,9), { LetOrUseKeyword = (3,4--3,7) - InKeyword = Some (3,14--3,16) }), (2,4--2,8), NoneAtLet, + InKeyword = Some (3,14--3,16) + EqualsRange = Some (3,10--3,11) }), (2,4--2,8), NoneAtLet, { LeadingKeyword = Let (2,0--2,3) InlineKeyword = None EqualsRange = Some (2,9--2,10) })], (2,0--5,9))], diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseBangContainsTheRangeOfTheEqualsSign.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseBangContainsTheRangeOfTheEqualsSign.fs.bsl index 19bef59c8a3..05609fbca45 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseBangContainsTheRangeOfTheEqualsSign.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseBangContainsTheRangeOfTheEqualsSign.fs.bsl @@ -27,7 +27,8 @@ ImplFile YieldOrReturn ((false, true), Const (Unit, (5,11--5,13)), (5,4--5,13), { YieldOrReturnKeyword = (5,4--5,10) }), (3,4--5,13), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,11--3,12) }), (2,5--6,1)), (2,0--6,1)), (2,0--6,1))], PreXmlDocEmpty, [], None, (2,0--6,1), { LeadingKeyword = None })], (true, true), diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl index 47612e2ac1c..37bc9c3b31c 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl @@ -20,7 +20,8 @@ ImplFile EqualsRange = Some (2,6--2,7) })], Const (Unit, (2,13--2,15)), (2,0--2,15), { LetOrUseKeyword = (2,0--2,3) - InKeyword = Some (2,10--2,12) }), (2,0--2,15))], + InKeyword = Some (2,10--2,12) + EqualsRange = Some (2,6--2,7) }), (2,0--2,15))], PreXmlDocEmpty, [], None, (2,0--2,15), { LeadingKeyword = None })], (true, true), { ConditionalDirectives = [] WarnDirectives = [] diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseDoesNotContainTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseDoesNotContainTheRangeOfInKeyword.fs.bsl index a7ba9540a40..05a52bec5e5 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseDoesNotContainTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseDoesNotContainTheRangeOfInKeyword.fs.bsl @@ -22,7 +22,8 @@ ImplFile EqualsRange = Some (3,6--3,7) })], Const (Unit, (4,0--4,2)), (3,0--4,2), { LetOrUseKeyword = (3,0--3,3) - InKeyword = None }), (2,0--4,2)), (2,0--4,2))], + InKeyword = None + EqualsRange = Some (3,6--3,7) }), (2,0--4,2)), (2,0--4,2))], PreXmlDocEmpty, [], None, (2,0--5,0), { LeadingKeyword = None })], (true, true), { ConditionalDirectives = [] WarnDirectives = [] diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWhereBodyExprStartsWithTokenOfTwoCharactersDoesNotContainTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWhereBodyExprStartsWithTokenOfTwoCharactersDoesNotContainTheRangeOfInKeyword.fs.bsl index 691c7762f37..583e33b78ec 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWhereBodyExprStartsWithTokenOfTwoCharactersDoesNotContainTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWhereBodyExprStartsWithTokenOfTwoCharactersDoesNotContainTheRangeOfInKeyword.fs.bsl @@ -41,7 +41,8 @@ ImplFile ([e1; Value], [(4,10--4,11)], [None; None]), None, (4,8--4,16))], [(4,6--4,7)], (4,0--4,16)), (3,0--4,16), { LetOrUseKeyword = (3,0--3,3) - InKeyword = None }), (2,0--4,16)), + InKeyword = None + EqualsRange = Some (3,7--3,8) }), (2,0--4,16)), (2,0--4,16))], PreXmlDocEmpty, [], None, (2,0--5,0), { LeadingKeyword = None })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWithRecursiveBindingContainsTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWithRecursiveBindingContainsTheRangeOfInKeyword.fs.bsl index b2ac0ca44e8..692b5495fcb 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWithRecursiveBindingContainsTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWithRecursiveBindingContainsTheRangeOfInKeyword.fs.bsl @@ -36,8 +36,10 @@ ImplFile EqualsRange = Some (4,10--4,11) })], Const (Unit, (5,4--5,6)), (3,4--5,6), { LetOrUseKeyword = (3,4--3,11) - InKeyword = Some (4,15--4,17) }), (2,0--5,6)), (2,0--5,6))], - PreXmlDocEmpty, [], None, (2,0--6,0), { LeadingKeyword = None })], - (true, true), { ConditionalDirectives = [] - WarnDirectives = [] - CodeComments = [] }, set [])) + InKeyword = Some (4,15--4,17) + EqualsRange = Some (3,14--3,15) }), (2,0--5,6)), + (2,0--5,6))], PreXmlDocEmpty, [], None, (2,0--6,0), + { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + WarnDirectives = [] + CodeComments = [] }, set [])) diff --git a/tests/service/data/SyntaxTree/Expression/Try with - Missing expr 04.fs.bsl b/tests/service/data/SyntaxTree/Expression/Try with - Missing expr 04.fs.bsl index 319880a8b0a..f3992cf7040 100644 --- a/tests/service/data/SyntaxTree/Expression/Try with - Missing expr 04.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/Try with - Missing expr 04.fs.bsl @@ -20,12 +20,13 @@ ImplFile EqualsRange = Some (5,6--5,7) })], ArbitraryAfterError ("seqExpr", (5,10--5,10)), (5,0--5,10), { LetOrUseKeyword = (5,0--5,3) - InKeyword = None }), [], (3,0--5,10), Yes (3,0--3,3), - Yes (5,10--5,10), { TryKeyword = (3,0--3,3) - TryToWithRange = (3,0--5,10) - WithKeyword = (5,10--5,10) - WithToEndRange = (3,0--5,10) }), - (3,0--5,10))], + InKeyword = None + EqualsRange = Some (5,6--5,7) }), [], (3,0--5,10), + Yes (3,0--3,3), Yes (5,10--5,10), + { TryKeyword = (3,0--3,3) + TryToWithRange = (3,0--5,10) + WithKeyword = (5,10--5,10) + WithToEndRange = (3,0--5,10) }), (3,0--5,10))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--5,10), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 01.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 01.fs.bsl index 1aa552d5f05..e0c44d14f8a 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 01.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 01.fs.bsl @@ -26,7 +26,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,18--4,19) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 02.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 02.fs.bsl index 6046708ca7f..a104e92410c 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 02.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 02.fs.bsl @@ -28,7 +28,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,20--4,21) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 03.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 03.fs.bsl index c065ea59e32..e0f29e22664 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 03.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 03.fs.bsl @@ -113,11 +113,13 @@ ImplFile Ident c, (6,11--6,20)), (6,11--6,22)), Ident d, (6,11--6,24)), (6,4--6,24), { YieldOrReturnKeyword = (6,4--6,10) }), - (5,4--6,24), { LetOrUseBangKeyword = (5,4--5,8) + (5,4--6,24), { LetOrUseKeyword = (5,4--5,8) + InKeyword = None EqualsRange = Some (5,26--5,27) }), (4,4--6,24), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,6--7,1)), - (3,0--7,1)), (3,0--7,1))], + InKeyword = None + EqualsRange = Some (4,25--4,26) }), + (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--7,1), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 04.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 04.fs.bsl index fc39d00e0a5..cd28aa03595 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 04.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 04.fs.bsl @@ -37,7 +37,8 @@ ImplFile EqualsRange = None })], ArbitraryAfterError ("declExpr3", (5,15--5,16)), (4,4--5,16), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }); Ident d], + InKeyword = None + EqualsRange = None }); Ident d], [(5,15--5,16)], (4,4--5,18)), (3,6--5,47)), (3,0--5,47)), (3,0--5,47))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 05.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 05.fs.bsl index 08008766b4d..d93e009f5d7 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 05.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 05.fs.bsl @@ -34,9 +34,11 @@ ImplFile { YieldOrReturnKeyword = (3,23--3,29) }), (3,21--3,33)), (3,15--3,33)), [], ImplicitZero (3,33--3,33), (3,0--3,33), - { LetOrUseBangKeyword = (3,0--3,4) + { LetOrUseKeyword = (3,0--3,4) + InKeyword = None EqualsRange = Some (3,13--3,14) }), (2,0--3,33), - { LetOrUseBangKeyword = (2,0--2,4) + { LetOrUseKeyword = (2,0--2,4) + InKeyword = None EqualsRange = Some (2,11--2,12) }), (2,0--3,33))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--3,33), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 06.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 06.fs.bsl index 591ef048599..77623805e3a 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 06.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 06.fs.bsl @@ -34,9 +34,11 @@ ImplFile { YieldOrReturnKeyword = (3,23--3,29) }), (3,21--3,33)), (3,15--3,33)), [], ImplicitZero (3,33--3,33), (3,0--3,33), - { LetOrUseBangKeyword = (3,0--3,4) + { LetOrUseKeyword = (3,0--3,4) + InKeyword = None EqualsRange = Some (3,13--3,14) }), (2,0--3,33), - { LetOrUseBangKeyword = (2,0--2,4) + { LetOrUseKeyword = (2,0--2,4) + InKeyword = None EqualsRange = Some (2,11--2,12) }), (2,0--3,33))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--3,33), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 07.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 07.fs.bsl index 9493eb7270f..ec976f9d78d 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 07.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 07.fs.bsl @@ -25,7 +25,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (5,4--5,15), { YieldOrReturnKeyword = (5,4--5,10) }), (3,4--5,15), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,35--3,36) }), (2,6--7,1)), (2,0--7,1)), (2,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 08.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 08.fs.bsl index 62bf5bc63db..df08719e64d 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 08.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 08.fs.bsl @@ -24,7 +24,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (4,4--4,15), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,15), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,33--3,34) }), (2,6--6,1)), (2,0--6,1)), (2,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 09.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 09.fs.bsl index 0516dc630a8..f60b9363710 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 09.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 09.fs.bsl @@ -24,7 +24,8 @@ ImplFile YieldOrReturn ((false, true), Ident value, (4,4--4,16), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,16), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,23--3,24) }), (2,6--5,1)), (2,0--5,1)), (2,0--5,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 10.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 10.fs.bsl index f3758aff371..43d9f3e2fe9 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 10.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 10.fs.bsl @@ -22,7 +22,8 @@ ImplFile YieldOrReturn ((false, true), Ident value, (4,4--4,16), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,16), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,21--3,22) }), (2,6--5,1)), (2,0--5,1)), (2,0--5,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 11.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 11.fs.bsl index 096e0effc20..10b908ae70f 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 11.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 11.fs.bsl @@ -30,7 +30,8 @@ ImplFile YieldOrReturn ((false, true), Ident value, (4,4--4,16), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,16), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,35--3,36) }), (2,6--5,1)), (2,0--5,1)), (2,0--5,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 12.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 12.fs.bsl index b274a8880f3..129c53c43f2 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 12.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 12.fs.bsl @@ -28,7 +28,8 @@ ImplFile YieldOrReturn ((false, true), Ident value, (4,4--4,16), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,16), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,33--3,34) }), (2,6--5,1)), (2,0--5,1)), (2,0--5,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 14.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 14.fs.bsl index c4ed5ee643f..93a922eddab 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 14.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 14.fs.bsl @@ -55,7 +55,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,19--4,20) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 15.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 15.fs.bsl index 1a461ef4b3e..a199310f6a3 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 15.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 15.fs.bsl @@ -36,7 +36,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (5,26--5,27) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 17.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 17.fs.bsl index 6f78c27dca1..25505e0b9e6 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 17.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 17.fs.bsl @@ -46,7 +46,8 @@ ImplFile (5,32--5,40), { YieldOrReturnKeyword = (5,32--5,38) }), (5,30--5,42)), (5,24--5,42)), [], ImplicitZero (5,42--5,42), (5,0--5,42), - { LetOrUseBangKeyword = (5,0--5,4) + { LetOrUseKeyword = (5,0--5,4) + InKeyword = None EqualsRange = Some (5,22--5,23) }), (5,0--5,42))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--5,42), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 18.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 18.fs.bsl index 8579d42db13..180faf48052 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 18.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 18.fs.bsl @@ -47,7 +47,8 @@ ImplFile (5,30--5,38), { YieldOrReturnKeyword = (5,30--5,36) }), (5,28--5,40)), (5,22--5,40)), [], ImplicitZero (5,40--5,40), (5,0--5,40), - { LetOrUseBangKeyword = (5,0--5,4) + { LetOrUseKeyword = (5,0--5,4) + InKeyword = None EqualsRange = Some (5,20--5,21) }), (5,0--5,40))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--5,40), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 19.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 19.fs.bsl index 4ccac506d64..ecd65b24301 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 19.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 19.fs.bsl @@ -57,11 +57,13 @@ ImplFile YieldOrReturn ((false, true), Ident x, (6,4--6,12), { YieldOrReturnKeyword = (6,4--6,10) }), - (5,4--6,12), { LetOrUseBangKeyword = (5,4--5,8) + (5,4--6,12), { LetOrUseKeyword = (5,4--5,8) + InKeyword = None EqualsRange = Some (5,26--5,27) }), (4,4--6,12), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,6--7,1)), - (3,0--7,1)), (3,0--7,1))], + InKeyword = None + EqualsRange = Some (4,25--4,26) }), + (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--7,1), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 20.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 20.fs.bsl index e14813fde0c..c9d8cdb5267 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 20.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 20.fs.bsl @@ -60,11 +60,13 @@ ImplFile YieldOrReturn ((false, true), Ident x, (6,4--6,12), { YieldOrReturnKeyword = (6,4--6,10) }), - (5,4--6,12), { LetOrUseBangKeyword = (5,4--5,8) + (5,4--6,12), { LetOrUseKeyword = (5,4--5,8) + InKeyword = None EqualsRange = Some (5,24--5,25) }), (4,4--6,12), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,6--7,1)), - (3,0--7,1)), (3,0--7,1))], + InKeyword = None + EqualsRange = Some (4,23--4,24) }), + (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--7,1), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 01.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 01.fs.bsl index 0aa056d6da5..865c5a7883d 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 01.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 01.fs.bsl @@ -46,7 +46,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (6,4--6,14), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,18--4,19) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 02.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 02.fs.bsl index 0f5f06df777..ed100564aef 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 02.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 02.fs.bsl @@ -50,7 +50,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (6,4--6,14), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,20--4,21) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 03.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 03.fs.bsl index 9d127609634..8c41c87de16 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 03.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 03.fs.bsl @@ -47,7 +47,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (6,4--6,15), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,15), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,46--4,47) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 04.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 04.fs.bsl index 2377382104e..1ad08e47ec6 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 04.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 04.fs.bsl @@ -45,7 +45,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (6,4--6,15), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,15), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,44--4,45) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 05.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 05.fs.bsl index 2309e7f9490..5fb229546c6 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 05.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 05.fs.bsl @@ -46,7 +46,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (6,4--6,15), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,15), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,46--4,47) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 06.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 06.fs.bsl index e46cfc2ef7c..5354fd61d49 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 06.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 06.fs.bsl @@ -52,7 +52,8 @@ ImplFile (6,17--6,18)), Ident value, (6,11--6,18)), Ident value2, (6,11--6,25)), (6,4--6,25), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,25), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,23--4,24) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 07.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 07.fs.bsl index 6bc6a07abec..31b4888fba6 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 07.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 07.fs.bsl @@ -48,7 +48,8 @@ ImplFile (6,17--6,18)), Ident value, (6,11--6,18)), Ident value2, (6,11--6,25)), (6,4--6,25), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,25), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,21--4,22) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 08.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 08.fs.bsl index 7ca03b4f9e3..f04efe243af 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 08.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 08.fs.bsl @@ -65,7 +65,8 @@ ImplFile (6,17--6,18)), Ident value, (6,11--6,18)), Ident value2, (6,11--6,25)), (6,4--6,25), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,25), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,35--4,36) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 09.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 09.fs.bsl index 0233ea37538..1da61fcb395 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 09.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 09.fs.bsl @@ -60,7 +60,8 @@ ImplFile (6,17--6,18)), Ident value, (6,11--6,18)), Ident value2, (6,11--6,25)), (6,4--6,25), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,25), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,33--4,34) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 10.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 10.fs.bsl index 4c616752ce3..49476bb21ad 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 10.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 10.fs.bsl @@ -57,7 +57,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,23--4,24) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 11.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 11.fs.bsl index 4c4991234a3..7305918522c 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 11.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 11.fs.bsl @@ -54,7 +54,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,21--4,22) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 12.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 12.fs.bsl index ffb04e5db54..db63b5cdd31 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 12.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 12.fs.bsl @@ -46,7 +46,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,16--4,17) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 13.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 13.fs.bsl index b79f90358d2..8d94b1d4d5c 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 13.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 13.fs.bsl @@ -60,7 +60,8 @@ ImplFile YieldOrReturn ((false, true), Ident first, (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,42--4,43) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 14.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 14.fs.bsl index eaefd1aa4ef..795342f5742 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 14.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 14.fs.bsl @@ -54,7 +54,8 @@ ImplFile YieldOrReturn ((false, true), Ident first, (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,40--4,41) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 15.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 15.fs.bsl index e60943e9933..9fdf1440fc8 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 15.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 15.fs.bsl @@ -38,7 +38,8 @@ ImplFile (Atomic, false, Ident asyncInt, Const (Unit, (4,37--4,39)), (4,29--4,39)), [], ImplicitZero (4,39--4,39), (4,4--5,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,27--4,28) }); Ident y], [(5,15--5,16)], (4,4--5,18)), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 16.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 16.fs.bsl index d9f64778935..65d6bfa4f5d 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 16.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 16.fs.bsl @@ -62,7 +62,8 @@ ImplFile YieldOrReturn ((false, true), Const (Unit, (6,11--6,13)), (6,4--6,13), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,13), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,27--4,28) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 17.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 17.fs.bsl index f801b2d1319..ea88513f59c 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 17.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 17.fs.bsl @@ -65,7 +65,8 @@ ImplFile YieldOrReturn ((false, true), Const (Unit, (6,11--6,13)), (6,4--6,13), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,13), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,27--4,28) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 18.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 18.fs.bsl index 037d6651228..2b833c4e6dd 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 18.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 18.fs.bsl @@ -56,7 +56,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,23--4,24) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 01.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 01.fs.bsl index a49e9a4abf3..68ffa0052e2 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 01.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 01.fs.bsl @@ -26,7 +26,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,18--4,19) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 02.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 02.fs.bsl index d402cdf754d..d108dbbdb26 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 02.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 02.fs.bsl @@ -28,7 +28,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,20--4,21) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 03.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 03.fs.bsl index a3eda56c6e0..7166b37a4b0 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 03.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 03.fs.bsl @@ -34,9 +34,11 @@ ImplFile { YieldOrReturnKeyword = (4,23--4,29) }), (4,21--4,33)), (4,15--4,33)), [], ImplicitZero (4,33--4,33), (4,0--4,33), - { LetOrUseBangKeyword = (4,0--4,4) + { LetOrUseKeyword = (4,0--4,4) + InKeyword = None EqualsRange = Some (4,13--4,14) }), (3,0--4,33), - { LetOrUseBangKeyword = (3,0--3,4) + { LetOrUseKeyword = (3,0--3,4) + InKeyword = None EqualsRange = Some (3,11--3,12) }), (3,0--4,33))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--4,33), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 04.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 04.fs.bsl index 3bf8a0ce44c..6253c5c42c5 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 04.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 04.fs.bsl @@ -34,9 +34,11 @@ ImplFile { YieldOrReturnKeyword = (4,23--4,29) }), (4,21--4,33)), (4,15--4,33)), [], ImplicitZero (4,33--4,33), (4,0--4,33), - { LetOrUseBangKeyword = (4,0--4,4) + { LetOrUseKeyword = (4,0--4,4) + InKeyword = None EqualsRange = Some (4,13--4,14) }), (3,0--4,33), - { LetOrUseBangKeyword = (3,0--3,4) + { LetOrUseKeyword = (3,0--3,4) + InKeyword = None EqualsRange = Some (3,11--3,12) }), (3,0--4,33))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--4,33), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 05.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 05.fs.bsl index 9042c097425..02b8514ab6a 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 05.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 05.fs.bsl @@ -25,7 +25,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,14--4,15) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, From 901cee97b462e413eb2e9883ffe3a1b77435958a Mon Sep 17 00:00:00 2001 From: edgargonzalez Date: Sat, 2 Aug 2025 09:06:32 +0200 Subject: [PATCH 08/10] Unify `SynExprLetOrUse` trivia --- buildtools/fslex/fslexast.fs | 2 +- .../Expressions/CheckComputationExpressions.fs | 16 ++++++++-------- .../Checking/Expressions/CheckExpressions.fs | 2 +- src/Compiler/SyntaxTree/ParseHelpers.fs | 11 +++++++++-- src/Compiler/SyntaxTree/SyntaxTree.fs | 2 +- src/Compiler/SyntaxTree/SyntaxTree.fsi | 2 +- src/Compiler/SyntaxTree/SyntaxTrivia.fs | 13 +------------ src/Compiler/SyntaxTree/SyntaxTrivia.fsi | 12 +----------- .../Binding/InlineKeywordInBinding.fs.bsl | 9 +++++---- ...SignShouldBePresentInLocalLetBinding.fs.bsl | 12 +++++++----- ...houldBePresentInLocalLetBindingTyped.fs.bsl | 12 +++++++----- ...uldBePresentInSynExprLetOrUseBinding.fs.bsl | 3 ++- ...hatStartsAtAndAndEndsAfterExpression.fs.bsl | 3 ++- ...ngeStartsAtAndAndEndsAfterExpression.fs.bsl | 3 ++- ...rLetOrUseContainsTheRangeOfInKeyword.fs.bsl | 6 ++++-- ...eBangContainsTheRangeOfTheEqualsSign.fs.bsl | 3 ++- ...rLetOrUseContainsTheRangeOfInKeyword.fs.bsl | 3 ++- ...UseDoesNotContainTheRangeOfInKeyword.fs.bsl | 3 ++- ...ersDoesNotContainTheRangeOfInKeyword.fs.bsl | 3 ++- ...veBindingContainsTheRangeOfInKeyword.fs.bsl | 12 +++++++----- .../Try with - Missing expr 04.fs.bsl | 13 +++++++------ .../LeadingKeyword/UseKeyword.fs.bsl | 12 +++++++----- .../LeadingKeyword/UseRecKeyword.fs.bsl | 12 +++++++----- .../RangeOfMultipleSynMatchClause.fs.bsl | 3 ++- .../RangeOfSingleSynMatchClause.fs.bsl | 3 ++- ...eOfSingleSynMatchClauseFollowedByBar.fs.bsl | 3 ++- .../Pattern/Typed - Missing type 05.fs.bsl | 3 ++- .../Pattern/Typed - Missing type 06.fs.bsl | 4 +++- .../Pattern/Typed - Missing type 09.fs.bsl | 3 ++- .../Pattern/Typed - Missing type 10.fs.bsl | 4 +++- .../Pattern/Typed - Missing type 11.fs.bsl | 4 +++- .../Pattern/Typed - Missing type 12.fs.bsl | 4 +++- ...InterpolatedStringOffsideInNestedLet.fs.bsl | 18 ++++++++++-------- .../SyntaxTree/SynType/Typed LetBang 01.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 02.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 03.fs.bsl | 8 +++++--- .../SyntaxTree/SynType/Typed LetBang 04.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 05.fs.bsl | 6 ++++-- .../SyntaxTree/SynType/Typed LetBang 06.fs.bsl | 6 ++++-- .../SyntaxTree/SynType/Typed LetBang 07.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 08.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 09.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 10.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 11.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 12.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 14.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 15.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 17.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 18.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed LetBang 19.fs.bsl | 8 +++++--- .../SyntaxTree/SynType/Typed LetBang 20.fs.bsl | 8 +++++--- .../SynType/Typed LetBang AndBang 01.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 02.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 03.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 04.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 05.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 06.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 07.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 08.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 09.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 10.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 11.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 12.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 13.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 14.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 15.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 16.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 17.fs.bsl | 3 ++- .../SynType/Typed LetBang AndBang 18.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed UseBang 01.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed UseBang 02.fs.bsl | 3 ++- .../SyntaxTree/SynType/Typed UseBang 03.fs.bsl | 6 ++++-- .../SyntaxTree/SynType/Typed UseBang 04.fs.bsl | 6 ++++-- .../SyntaxTree/SynType/Typed UseBang 05.fs.bsl | 3 ++- 74 files changed, 219 insertions(+), 149 deletions(-) diff --git a/buildtools/fslex/fslexast.fs b/buildtools/fslex/fslexast.fs index b621ac2dcdd..6c9e790101c 100644 --- a/buildtools/fslex/fslexast.fs +++ b/buildtools/fslex/fslexast.fs @@ -123,7 +123,7 @@ let GetSpecificUnicodeChars() = let GetSingleCharAlphabet: Parser> = fun ctx -> if ctx.unicode - then Set.ofList [ yield! { char 0 .. char <| numLowUnicodeChars-1 } + then Set.ofList [ yield! seq { char 0 .. char <| numLowUnicodeChars-1 } yield! GetSpecificUnicodeChars() ] else Set.ofList [ char 0 .. char 255 ] diff --git a/src/Compiler/Checking/Expressions/CheckComputationExpressions.fs b/src/Compiler/Checking/Expressions/CheckComputationExpressions.fs index 00b992a6f92..3258dbbb9a5 100644 --- a/src/Compiler/Checking/Expressions/CheckComputationExpressions.fs +++ b/src/Compiler/Checking/Expressions/CheckComputationExpressions.fs @@ -861,7 +861,7 @@ let (|ExprAsUseBang|_|) expr = rhs = rhsExpr andBangs = andBangs body = innerComp - trivia = { LetOrUseBangKeyword = mBind }) -> ValueSome(spBind, isFromSource, pat, rhsExpr, andBangs, innerComp, mBind) + trivia = { LetOrUseKeyword = mBind }) -> ValueSome(spBind, isFromSource, pat, rhsExpr, andBangs, innerComp, mBind) | _ -> ValueNone [] @@ -875,7 +875,7 @@ let (|ExprAsLetBang|_|) expr = rhs = letRhsExpr andBangs = andBangBindings body = innerComp - trivia = { LetOrUseBangKeyword = mBind }) -> ValueSome(spBind, isFromSource, letPat, letRhsExpr, andBangBindings, innerComp, mBind) + trivia = { LetOrUseKeyword = mBind }) -> ValueSome(spBind, isFromSource, letPat, letRhsExpr, andBangBindings, innerComp, mBind) | _ -> ValueNone // "cexpr; cexpr" is treated as builder.Combine(cexpr1, cexpr1) @@ -1393,7 +1393,7 @@ let rec TryTranslateComputationExpression [], setCondExpr, mGuard, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) let whileExpr = @@ -1422,7 +1422,7 @@ let rec TryTranslateComputationExpression [], body, mGuard, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) TryTranslateComputationExpression ceenv CompExprTranslationPass.Initial q varSpace rewrittenWhileExpr translatedCtxt @@ -1637,7 +1637,7 @@ let rec TryTranslateComputationExpression [], innerComp2, m, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero )) translatedCtxt ) @@ -2393,7 +2393,7 @@ and ConsumeCustomOpClauses [], contExpr, intoPat.Range, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) else SynExpr.ForEach( @@ -2434,7 +2434,7 @@ and ConsumeCustomOpClauses [], compClausesExpr, compClausesExpr.Range, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) else SynExpr.ForEach( @@ -2697,7 +2697,7 @@ and TranslateComputationExpression (ceenv: ComputationExpressionContext<'a>) fir [], bodyExpr, m, - SynExprLetOrUseBangTrivia.Zero + SynExprLetOrUseTrivia.Zero ) TranslateComputationExpression ceenv CompExprTranslationPass.Initial q varSpace letBangBind translatedCtxt diff --git a/src/Compiler/Checking/Expressions/CheckExpressions.fs b/src/Compiler/Checking/Expressions/CheckExpressions.fs index 5862b907e05..1d191d77fd7 100644 --- a/src/Compiler/Checking/Expressions/CheckExpressions.fs +++ b/src/Compiler/Checking/Expressions/CheckExpressions.fs @@ -6072,7 +6072,7 @@ and TcExprUndelayed (cenv: cenv) (overallTy: OverallTy) env tpenv (synExpr: SynE | SynExpr.DoBang (trivia = { DoBangKeyword = m }) | SynExpr.MatchBang (trivia = { MatchBangKeyword = m }) | SynExpr.WhileBang (range = m) - | SynExpr.LetOrUseBang (trivia = { LetOrUseBangKeyword = m }) -> + | SynExpr.LetOrUseBang (trivia = { LetOrUseKeyword = m }) -> error(Error(FSComp.SR.tcConstructRequiresComputationExpression(), m)) | SynExpr.IndexFromEnd (rightExpr, m) -> diff --git a/src/Compiler/SyntaxTree/ParseHelpers.fs b/src/Compiler/SyntaxTree/ParseHelpers.fs index 4aeffc3a056..64b525e1afd 100644 --- a/src/Compiler/SyntaxTree/ParseHelpers.fs +++ b/src/Compiler/SyntaxTree/ParseHelpers.fs @@ -1071,9 +1071,10 @@ let mkLetExpression // Create let! or use! expression let spBind = DebugPointAtBinding.Yes(unionRanges mKeyword rhs.Range) - let trivia: SynExprLetOrUseBangTrivia = + let trivia: SynExprLetOrUseTrivia = { - LetOrUseBangKeyword = mKeyword + LetOrUseKeyword = mKeyword + InKeyword = mIn EqualsRange = mEquals } // isFromSource is true for user-written code @@ -1106,6 +1107,11 @@ let mkLetExpression | SynBinding(trivia = trivia) :: _ -> trivia.LeadingKeyword.Range | _ -> range0 + let mEquals = + match decls with + | SynBinding(trivia = trivia) :: _ -> trivia.EqualsRange + | _ -> None + SynExpr.LetOrUse( isRec, isUse, // Pass through the isUse flag from binding info @@ -1115,6 +1121,7 @@ let mkLetExpression { LetOrUseKeyword = mLetOrUse InKeyword = mIn' + EqualsRange = mEquals } ) | None -> SynExpr.FromParseError(body, mWhole) diff --git a/src/Compiler/SyntaxTree/SyntaxTree.fs b/src/Compiler/SyntaxTree/SyntaxTree.fs index 5e3542f6b69..acbb6d0a26e 100644 --- a/src/Compiler/SyntaxTree/SyntaxTree.fs +++ b/src/Compiler/SyntaxTree/SyntaxTree.fs @@ -729,7 +729,7 @@ type SynExpr = andBangs: SynExprAndBang list * body: SynExpr * range: range * - trivia: SynExprLetOrUseBangTrivia + trivia: SynExprLetOrUseTrivia | MatchBang of matchDebugPoint: DebugPointAtBinding * diff --git a/src/Compiler/SyntaxTree/SyntaxTree.fsi b/src/Compiler/SyntaxTree/SyntaxTree.fsi index aa6f394d6c4..2dd3bb35aae 100644 --- a/src/Compiler/SyntaxTree/SyntaxTree.fsi +++ b/src/Compiler/SyntaxTree/SyntaxTree.fsi @@ -899,7 +899,7 @@ type SynExpr = andBangs: SynExprAndBang list * body: SynExpr * range: range * - trivia: SynExprLetOrUseBangTrivia + trivia: SynExprLetOrUseTrivia /// F# syntax: match! expr with pat1 -> expr | ... | patN -> exprN | MatchBang of diff --git a/src/Compiler/SyntaxTree/SyntaxTrivia.fs b/src/Compiler/SyntaxTree/SyntaxTrivia.fs index 56002949b5c..7befe5e4a01 100644 --- a/src/Compiler/SyntaxTree/SyntaxTrivia.fs +++ b/src/Compiler/SyntaxTree/SyntaxTrivia.fs @@ -94,24 +94,13 @@ type SynExprLetOrUseTrivia = { LetOrUseKeyword: range InKeyword: range option + EqualsRange: range option } static member Zero: SynExprLetOrUseTrivia = { InKeyword = None LetOrUseKeyword = range0 - } - -[] -type SynExprLetOrUseBangTrivia = - { - LetOrUseBangKeyword: range - EqualsRange: range option - } - - static member Zero: SynExprLetOrUseBangTrivia = - { - LetOrUseBangKeyword = range0 EqualsRange = None } diff --git a/src/Compiler/SyntaxTree/SyntaxTrivia.fsi b/src/Compiler/SyntaxTree/SyntaxTrivia.fsi index 89d7124e5f1..9a0b8d6b363 100644 --- a/src/Compiler/SyntaxTree/SyntaxTrivia.fsi +++ b/src/Compiler/SyntaxTree/SyntaxTrivia.fsi @@ -132,21 +132,11 @@ type SynExprLetOrUseTrivia = LetOrUseKeyword: range /// The syntax range of the `in` keyword. InKeyword: range option - } - - static member Zero: SynExprLetOrUseTrivia -/// Represents additional information for SynExpr.LetOrUseBang -[] -type SynExprLetOrUseBangTrivia = - { - /// The syntax range of the `let!` or `use!` keyword. - LetOrUseBangKeyword: range - /// The syntax range of the `=` token. EqualsRange: range option } - static member Zero: SynExprLetOrUseBangTrivia + static member Zero: SynExprLetOrUseTrivia /// Represents additional information for SynExpr.Match [] diff --git a/tests/service/data/SyntaxTree/Binding/InlineKeywordInBinding.fs.bsl b/tests/service/data/SyntaxTree/Binding/InlineKeywordInBinding.fs.bsl index 3213618de10..9d1c6939e3e 100644 --- a/tests/service/data/SyntaxTree/Binding/InlineKeywordInBinding.fs.bsl +++ b/tests/service/data/SyntaxTree/Binding/InlineKeywordInBinding.fs.bsl @@ -46,10 +46,11 @@ ImplFile EqualsRange = Some (3,21--3,22) })], Const (Unit, (4,4--4,6)), (3,4--4,6), { LetOrUseKeyword = (3,4--3,7) - InKeyword = None }), (2,11--2,16), NoneAtLet, - { LeadingKeyword = Let (2,0--2,3) - InlineKeyword = Some (2,4--2,10) - EqualsRange = Some (2,17--2,18) })], (2,0--4,6))], + InKeyword = None + EqualsRange = Some (3,21--3,22) }), (2,11--2,16), + NoneAtLet, { LeadingKeyword = Let (2,0--2,3) + InlineKeyword = Some (2,4--2,10) + EqualsRange = Some (2,17--2,18) })], (2,0--4,6))], PreXmlDocEmpty, [], None, (2,0--5,0), { LeadingKeyword = None })], (true, true), { ConditionalDirectives = [] WarnDirectives = [] diff --git a/tests/service/data/SyntaxTree/Binding/RangeOfEqualSignShouldBePresentInLocalLetBinding.fs.bsl b/tests/service/data/SyntaxTree/Binding/RangeOfEqualSignShouldBePresentInLocalLetBinding.fs.bsl index 9921095320e..c54522f64b2 100644 --- a/tests/service/data/SyntaxTree/Binding/RangeOfEqualSignShouldBePresentInLocalLetBinding.fs.bsl +++ b/tests/service/data/SyntaxTree/Binding/RangeOfEqualSignShouldBePresentInLocalLetBinding.fs.bsl @@ -21,8 +21,10 @@ ImplFile EqualsRange = Some (3,10--3,11) })], Const (Unit, (4,4--4,6)), (3,4--4,6), { LetOrUseKeyword = (3,4--3,7) - InKeyword = None }), (2,0--4,6)), (2,0--4,6))], - PreXmlDocEmpty, [], None, (2,0--5,0), { LeadingKeyword = None })], - (true, true), { ConditionalDirectives = [] - WarnDirectives = [] - CodeComments = [] }, set [])) + InKeyword = None + EqualsRange = Some (3,10--3,11) }), (2,0--4,6)), + (2,0--4,6))], PreXmlDocEmpty, [], None, (2,0--5,0), + { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + WarnDirectives = [] + CodeComments = [] }, set [])) diff --git a/tests/service/data/SyntaxTree/Binding/RangeOfEqualSignShouldBePresentInLocalLetBindingTyped.fs.bsl b/tests/service/data/SyntaxTree/Binding/RangeOfEqualSignShouldBePresentInLocalLetBindingTyped.fs.bsl index 770bfd5f4d5..ce9d335891d 100644 --- a/tests/service/data/SyntaxTree/Binding/RangeOfEqualSignShouldBePresentInLocalLetBindingTyped.fs.bsl +++ b/tests/service/data/SyntaxTree/Binding/RangeOfEqualSignShouldBePresentInLocalLetBindingTyped.fs.bsl @@ -32,8 +32,10 @@ ImplFile EqualsRange = Some (3,15--3,16) })], Const (Unit, (4,4--4,6)), (3,4--4,6), { LetOrUseKeyword = (3,4--3,7) - InKeyword = None }), (2,0--4,6)), (2,0--4,6))], - PreXmlDocEmpty, [], None, (2,0--5,0), { LeadingKeyword = None })], - (true, true), { ConditionalDirectives = [] - WarnDirectives = [] - CodeComments = [] }, set [])) + InKeyword = None + EqualsRange = Some (3,15--3,16) }), (2,0--4,6)), + (2,0--4,6))], PreXmlDocEmpty, [], None, (2,0--5,0), + { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + WarnDirectives = [] + CodeComments = [] }, set [])) diff --git a/tests/service/data/SyntaxTree/Binding/RangeOfLetKeywordShouldBePresentInSynExprLetOrUseBinding.fs.bsl b/tests/service/data/SyntaxTree/Binding/RangeOfLetKeywordShouldBePresentInSynExprLetOrUseBinding.fs.bsl index 747fdcbc1e2..2e096ce46f6 100644 --- a/tests/service/data/SyntaxTree/Binding/RangeOfLetKeywordShouldBePresentInSynExprLetOrUseBinding.fs.bsl +++ b/tests/service/data/SyntaxTree/Binding/RangeOfLetKeywordShouldBePresentInSynExprLetOrUseBinding.fs.bsl @@ -36,7 +36,8 @@ ImplFile EqualsRange = Some (3,12--3,13) })], Const (Unit, (4,4--4,6)), (3,4--4,6), { LetOrUseKeyword = (3,4--3,7) - InKeyword = None }), (2,4--2,5), NoneAtLet, + InKeyword = None + EqualsRange = Some (3,12--3,13) }), (2,4--2,5), NoneAtLet, { LeadingKeyword = Let (2,0--2,3) InlineKeyword = None EqualsRange = Some (2,6--2,7) })], (2,0--4,6))], diff --git a/tests/service/data/SyntaxTree/ComputationExpression/MultipleSynExprAndBangHaveRangeThatStartsAtAndAndEndsAfterExpression.fs.bsl b/tests/service/data/SyntaxTree/ComputationExpression/MultipleSynExprAndBangHaveRangeThatStartsAtAndAndEndsAfterExpression.fs.bsl index a9f281321fa..bdee1f621ed 100644 --- a/tests/service/data/SyntaxTree/ComputationExpression/MultipleSynExprAndBangHaveRangeThatStartsAtAndAndEndsAfterExpression.fs.bsl +++ b/tests/service/data/SyntaxTree/ComputationExpression/MultipleSynExprAndBangHaveRangeThatStartsAtAndAndEndsAfterExpression.fs.bsl @@ -41,7 +41,8 @@ ImplFile YieldOrReturn ((false, true), Ident bar, (6,4--6,14), { YieldOrReturnKeyword = (6,4--6,10) }), (3,4--6,14), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,13--3,14) }), (2,6--7,1)), (2,0--7,1)), (2,0--7,1))], PreXmlDocEmpty, [], None, (2,0--7,1), { LeadingKeyword = None })], (true, true), diff --git a/tests/service/data/SyntaxTree/ComputationExpression/SynExprAndBangRangeStartsAtAndAndEndsAfterExpression.fs.bsl b/tests/service/data/SyntaxTree/ComputationExpression/SynExprAndBangRangeStartsAtAndAndEndsAfterExpression.fs.bsl index 031ace760eb..58d455dacb1 100644 --- a/tests/service/data/SyntaxTree/ComputationExpression/SynExprAndBangRangeStartsAtAndAndEndsAfterExpression.fs.bsl +++ b/tests/service/data/SyntaxTree/ComputationExpression/SynExprAndBangRangeStartsAtAndAndEndsAfterExpression.fs.bsl @@ -31,7 +31,8 @@ ImplFile YieldOrReturn ((false, true), Ident bar, (7,4--7,14), { YieldOrReturnKeyword = (7,4--7,10) }), (3,4--7,14), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,13--3,14) }), (2,6--8,1)), (2,0--8,1)), (2,0--8,1))], PreXmlDocEmpty, [], None, (2,0--8,1), { LeadingKeyword = None })], (true, true), diff --git a/tests/service/data/SyntaxTree/Expression/NestedSynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/NestedSynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl index 51a31c623dd..fc36bd59dfc 100644 --- a/tests/service/data/SyntaxTree/Expression/NestedSynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/NestedSynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl @@ -55,9 +55,11 @@ ImplFile (5,6--5,7)), Ident x, (5,4--5,7)), Ident y, (5,4--5,9)), (4,4--5,9), { LetOrUseKeyword = (4,4--4,7) - InKeyword = Some (4,14--4,16) }), (3,4--5,9), + InKeyword = Some (4,14--4,16) + EqualsRange = Some (4,10--4,11) }), (3,4--5,9), { LetOrUseKeyword = (3,4--3,7) - InKeyword = Some (3,14--3,16) }), (2,4--2,8), NoneAtLet, + InKeyword = Some (3,14--3,16) + EqualsRange = Some (3,10--3,11) }), (2,4--2,8), NoneAtLet, { LeadingKeyword = Let (2,0--2,3) InlineKeyword = None EqualsRange = Some (2,9--2,10) })], (2,0--5,9))], diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseBangContainsTheRangeOfTheEqualsSign.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseBangContainsTheRangeOfTheEqualsSign.fs.bsl index 19bef59c8a3..05609fbca45 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseBangContainsTheRangeOfTheEqualsSign.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseBangContainsTheRangeOfTheEqualsSign.fs.bsl @@ -27,7 +27,8 @@ ImplFile YieldOrReturn ((false, true), Const (Unit, (5,11--5,13)), (5,4--5,13), { YieldOrReturnKeyword = (5,4--5,10) }), (3,4--5,13), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,11--3,12) }), (2,5--6,1)), (2,0--6,1)), (2,0--6,1))], PreXmlDocEmpty, [], None, (2,0--6,1), { LeadingKeyword = None })], (true, true), diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl index 47612e2ac1c..37bc9c3b31c 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseContainsTheRangeOfInKeyword.fs.bsl @@ -20,7 +20,8 @@ ImplFile EqualsRange = Some (2,6--2,7) })], Const (Unit, (2,13--2,15)), (2,0--2,15), { LetOrUseKeyword = (2,0--2,3) - InKeyword = Some (2,10--2,12) }), (2,0--2,15))], + InKeyword = Some (2,10--2,12) + EqualsRange = Some (2,6--2,7) }), (2,0--2,15))], PreXmlDocEmpty, [], None, (2,0--2,15), { LeadingKeyword = None })], (true, true), { ConditionalDirectives = [] WarnDirectives = [] diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseDoesNotContainTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseDoesNotContainTheRangeOfInKeyword.fs.bsl index a7ba9540a40..05a52bec5e5 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseDoesNotContainTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseDoesNotContainTheRangeOfInKeyword.fs.bsl @@ -22,7 +22,8 @@ ImplFile EqualsRange = Some (3,6--3,7) })], Const (Unit, (4,0--4,2)), (3,0--4,2), { LetOrUseKeyword = (3,0--3,3) - InKeyword = None }), (2,0--4,2)), (2,0--4,2))], + InKeyword = None + EqualsRange = Some (3,6--3,7) }), (2,0--4,2)), (2,0--4,2))], PreXmlDocEmpty, [], None, (2,0--5,0), { LeadingKeyword = None })], (true, true), { ConditionalDirectives = [] WarnDirectives = [] diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWhereBodyExprStartsWithTokenOfTwoCharactersDoesNotContainTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWhereBodyExprStartsWithTokenOfTwoCharactersDoesNotContainTheRangeOfInKeyword.fs.bsl index 691c7762f37..583e33b78ec 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWhereBodyExprStartsWithTokenOfTwoCharactersDoesNotContainTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWhereBodyExprStartsWithTokenOfTwoCharactersDoesNotContainTheRangeOfInKeyword.fs.bsl @@ -41,7 +41,8 @@ ImplFile ([e1; Value], [(4,10--4,11)], [None; None]), None, (4,8--4,16))], [(4,6--4,7)], (4,0--4,16)), (3,0--4,16), { LetOrUseKeyword = (3,0--3,3) - InKeyword = None }), (2,0--4,16)), + InKeyword = None + EqualsRange = Some (3,7--3,8) }), (2,0--4,16)), (2,0--4,16))], PreXmlDocEmpty, [], None, (2,0--5,0), { LeadingKeyword = None })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWithRecursiveBindingContainsTheRangeOfInKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWithRecursiveBindingContainsTheRangeOfInKeyword.fs.bsl index b2ac0ca44e8..692b5495fcb 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWithRecursiveBindingContainsTheRangeOfInKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprLetOrUseWithRecursiveBindingContainsTheRangeOfInKeyword.fs.bsl @@ -36,8 +36,10 @@ ImplFile EqualsRange = Some (4,10--4,11) })], Const (Unit, (5,4--5,6)), (3,4--5,6), { LetOrUseKeyword = (3,4--3,11) - InKeyword = Some (4,15--4,17) }), (2,0--5,6)), (2,0--5,6))], - PreXmlDocEmpty, [], None, (2,0--6,0), { LeadingKeyword = None })], - (true, true), { ConditionalDirectives = [] - WarnDirectives = [] - CodeComments = [] }, set [])) + InKeyword = Some (4,15--4,17) + EqualsRange = Some (3,14--3,15) }), (2,0--5,6)), + (2,0--5,6))], PreXmlDocEmpty, [], None, (2,0--6,0), + { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + WarnDirectives = [] + CodeComments = [] }, set [])) diff --git a/tests/service/data/SyntaxTree/Expression/Try with - Missing expr 04.fs.bsl b/tests/service/data/SyntaxTree/Expression/Try with - Missing expr 04.fs.bsl index 319880a8b0a..f3992cf7040 100644 --- a/tests/service/data/SyntaxTree/Expression/Try with - Missing expr 04.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/Try with - Missing expr 04.fs.bsl @@ -20,12 +20,13 @@ ImplFile EqualsRange = Some (5,6--5,7) })], ArbitraryAfterError ("seqExpr", (5,10--5,10)), (5,0--5,10), { LetOrUseKeyword = (5,0--5,3) - InKeyword = None }), [], (3,0--5,10), Yes (3,0--3,3), - Yes (5,10--5,10), { TryKeyword = (3,0--3,3) - TryToWithRange = (3,0--5,10) - WithKeyword = (5,10--5,10) - WithToEndRange = (3,0--5,10) }), - (3,0--5,10))], + InKeyword = None + EqualsRange = Some (5,6--5,7) }), [], (3,0--5,10), + Yes (3,0--3,3), Yes (5,10--5,10), + { TryKeyword = (3,0--3,3) + TryToWithRange = (3,0--5,10) + WithKeyword = (5,10--5,10) + WithToEndRange = (3,0--5,10) }), (3,0--5,10))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--5,10), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/LeadingKeyword/UseKeyword.fs.bsl b/tests/service/data/SyntaxTree/LeadingKeyword/UseKeyword.fs.bsl index 913dfadb878..1774b119f59 100644 --- a/tests/service/data/SyntaxTree/LeadingKeyword/UseKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/LeadingKeyword/UseKeyword.fs.bsl @@ -24,8 +24,10 @@ ImplFile EqualsRange = Some (3,10--3,11) })], Const (Unit, (4,4--4,6)), (3,4--4,6), { LetOrUseKeyword = (3,4--3,7) - InKeyword = None }), (2,0--4,6)), (2,0--4,6))], - PreXmlDocEmpty, [], None, (2,0--5,0), { LeadingKeyword = None })], - (true, true), { ConditionalDirectives = [] - WarnDirectives = [] - CodeComments = [] }, set [])) + InKeyword = None + EqualsRange = Some (3,10--3,11) }), (2,0--4,6)), + (2,0--4,6))], PreXmlDocEmpty, [], None, (2,0--5,0), + { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + WarnDirectives = [] + CodeComments = [] }, set [])) diff --git a/tests/service/data/SyntaxTree/LeadingKeyword/UseRecKeyword.fs.bsl b/tests/service/data/SyntaxTree/LeadingKeyword/UseRecKeyword.fs.bsl index eac3e1cf38c..aececc8348e 100644 --- a/tests/service/data/SyntaxTree/LeadingKeyword/UseRecKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/LeadingKeyword/UseRecKeyword.fs.bsl @@ -24,8 +24,10 @@ ImplFile EqualsRange = Some (3,14--3,15) })], Const (Unit, (4,4--4,6)), (3,4--4,6), { LetOrUseKeyword = (3,4--3,11) - InKeyword = None }), (2,0--4,6)), (2,0--4,6))], - PreXmlDocEmpty, [], None, (2,0--5,0), { LeadingKeyword = None })], - (true, true), { ConditionalDirectives = [] - WarnDirectives = [] - CodeComments = [] }, set [])) + InKeyword = None + EqualsRange = Some (3,14--3,15) }), (2,0--4,6)), + (2,0--4,6))], PreXmlDocEmpty, [], None, (2,0--5,0), + { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + WarnDirectives = [] + CodeComments = [] }, set [])) diff --git a/tests/service/data/SyntaxTree/MatchClause/RangeOfMultipleSynMatchClause.fs.bsl b/tests/service/data/SyntaxTree/MatchClause/RangeOfMultipleSynMatchClause.fs.bsl index 25fb2192c73..19f2154a6c9 100644 --- a/tests/service/data/SyntaxTree/MatchClause/RangeOfMultipleSynMatchClause.fs.bsl +++ b/tests/service/data/SyntaxTree/MatchClause/RangeOfMultipleSynMatchClause.fs.bsl @@ -26,7 +26,8 @@ ImplFile App (NonAtomic, false, Ident Some, Ident content, (4,4--4,16)), (3,4--4,16), { LetOrUseKeyword = (3,4--3,7) - InKeyword = None }), + InKeyword = None + EqualsRange = Some (3,16--3,17) }), [SynMatchClause (Named (SynIdent (ex, None), false, None, (6,2--6,4)), None, Sequential diff --git a/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClause.fs.bsl b/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClause.fs.bsl index 547027c53ab..e5bbe56cba7 100644 --- a/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClause.fs.bsl +++ b/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClause.fs.bsl @@ -26,7 +26,8 @@ ImplFile App (NonAtomic, false, Ident Some, Ident content, (4,4--4,16)), (3,4--4,16), { LetOrUseKeyword = (3,4--3,7) - InKeyword = None }), + InKeyword = None + EqualsRange = Some (3,16--3,17) }), [SynMatchClause (Named (SynIdent (ex, None), false, None, (5,5--5,7)), None, Sequential diff --git a/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClauseFollowedByBar.fs.bsl b/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClauseFollowedByBar.fs.bsl index 11f88dadedb..21f8e8cdb6b 100644 --- a/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClauseFollowedByBar.fs.bsl +++ b/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClauseFollowedByBar.fs.bsl @@ -26,7 +26,8 @@ ImplFile App (NonAtomic, false, Ident Some, Ident content, (4,4--4,16)), (3,4--4,16), { LetOrUseKeyword = (3,4--3,7) - InKeyword = None }), + InKeyword = None + EqualsRange = Some (3,16--3,17) }), [SynMatchClause (Named (SynIdent (ex, None), false, None, (6,2--6,4)), None, Const (Unit, (7,4--7,6)), (6,2--7,6), Yes, diff --git a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 05.fs.bsl b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 05.fs.bsl index 12785905c05..d4c056f191b 100644 --- a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 05.fs.bsl +++ b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 05.fs.bsl @@ -31,7 +31,8 @@ ImplFile EqualsRange = None })], ArbitraryAfterError ("seqExpr", (4,10--4,10)), (4,4--4,10), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (4,4--4,10)), + InKeyword = None + EqualsRange = None }), (4,4--4,10)), (3,0--4,10)), (3,0--4,10))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--4,10), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 06.fs.bsl b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 06.fs.bsl index a6e663f076a..229f126fa39 100644 --- a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 06.fs.bsl +++ b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 06.fs.bsl @@ -28,7 +28,9 @@ ImplFile EqualsRange = Some (4,11--4,12) })], Const (Unit, (6,4--6,6)), (4,4--6,6), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,0--6,6)), (3,0--6,6))], + InKeyword = None + EqualsRange = Some (4,11--4,12) }), (3,0--6,6)), + (3,0--6,6))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--6,6), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 09.fs.bsl b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 09.fs.bsl index bdac43a6b34..bf0847e0ea0 100644 --- a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 09.fs.bsl +++ b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 09.fs.bsl @@ -26,7 +26,8 @@ ImplFile InlineKeyword = None EqualsRange = None })], Const (Unit, (6,4--6,6)), (4,4--6,6), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,0--6,6)), (3,0--6,6))], + InKeyword = None + EqualsRange = None }), (3,0--6,6)), (3,0--6,6))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--6,6), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 10.fs.bsl b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 10.fs.bsl index b18b97bfe76..65b1b0d7a95 100644 --- a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 10.fs.bsl +++ b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 10.fs.bsl @@ -26,7 +26,9 @@ ImplFile EqualsRange = Some (4,13--4,14) })], Const (Unit, (6,4--6,6)), (4,4--6,6), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,0--6,6)), (3,0--6,6))], + InKeyword = None + EqualsRange = Some (4,13--4,14) }), (3,0--6,6)), + (3,0--6,6))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--6,6), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 11.fs.bsl b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 11.fs.bsl index be2e2e830c2..4980b86a481 100644 --- a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 11.fs.bsl +++ b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 11.fs.bsl @@ -32,7 +32,9 @@ ImplFile EqualsRange = Some (4,15--4,16) })], Const (Unit, (6,4--6,6)), (4,4--6,6), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,0--6,6)), (3,0--6,6))], + InKeyword = None + EqualsRange = Some (4,15--4,16) }), (3,0--6,6)), + (3,0--6,6))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--6,6), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 12.fs.bsl b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 12.fs.bsl index 9b2df1c8190..b9200e91fd0 100644 --- a/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 12.fs.bsl +++ b/tests/service/data/SyntaxTree/Pattern/Typed - Missing type 12.fs.bsl @@ -40,7 +40,9 @@ ImplFile EqualsRange = Some (4,18--4,19) })], Const (Unit, (6,4--6,6)), (4,4--6,6), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,0--6,6)), (3,0--6,6))], + InKeyword = None + EqualsRange = Some (4,18--4,19) }), (3,0--6,6)), + (3,0--6,6))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--6,6), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/String/InterpolatedStringOffsideInNestedLet.fs.bsl b/tests/service/data/SyntaxTree/String/InterpolatedStringOffsideInNestedLet.fs.bsl index 5d675200d7c..d8e5ea12eab 100644 --- a/tests/service/data/SyntaxTree/String/InterpolatedStringOffsideInNestedLet.fs.bsl +++ b/tests/service/data/SyntaxTree/String/InterpolatedStringOffsideInNestedLet.fs.bsl @@ -32,11 +32,13 @@ ImplFile InlineKeyword = None EqualsRange = Some (2,10--2,11) })], Ident b, (2,4--5,5), { LetOrUseKeyword = (2,4--2,7) - InKeyword = None }), (1,4--1,5), NoneAtLet, - { LeadingKeyword = Let (1,0--1,3) - InlineKeyword = None - EqualsRange = Some (1,6--1,7) })], (1,0--5,5))], - PreXmlDocEmpty, [], None, (1,0--5,5), { LeadingKeyword = None })], - (true, true), { ConditionalDirectives = [] - WarnDirectives = [] - CodeComments = [] }, set [])) + InKeyword = None + EqualsRange = Some (2,10--2,11) }), + (1,4--1,5), NoneAtLet, { LeadingKeyword = Let (1,0--1,3) + InlineKeyword = None + EqualsRange = Some (1,6--1,7) })], + (1,0--5,5))], PreXmlDocEmpty, [], None, (1,0--5,5), + { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + WarnDirectives = [] + CodeComments = [] }, set [])) diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 01.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 01.fs.bsl index 1aa552d5f05..e0c44d14f8a 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 01.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 01.fs.bsl @@ -26,7 +26,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,18--4,19) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 02.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 02.fs.bsl index 6046708ca7f..a104e92410c 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 02.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 02.fs.bsl @@ -28,7 +28,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,20--4,21) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 03.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 03.fs.bsl index c065ea59e32..e0f29e22664 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 03.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 03.fs.bsl @@ -113,11 +113,13 @@ ImplFile Ident c, (6,11--6,20)), (6,11--6,22)), Ident d, (6,11--6,24)), (6,4--6,24), { YieldOrReturnKeyword = (6,4--6,10) }), - (5,4--6,24), { LetOrUseBangKeyword = (5,4--5,8) + (5,4--6,24), { LetOrUseKeyword = (5,4--5,8) + InKeyword = None EqualsRange = Some (5,26--5,27) }), (4,4--6,24), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,6--7,1)), - (3,0--7,1)), (3,0--7,1))], + InKeyword = None + EqualsRange = Some (4,25--4,26) }), + (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--7,1), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 04.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 04.fs.bsl index fc39d00e0a5..cd28aa03595 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 04.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 04.fs.bsl @@ -37,7 +37,8 @@ ImplFile EqualsRange = None })], ArbitraryAfterError ("declExpr3", (5,15--5,16)), (4,4--5,16), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }); Ident d], + InKeyword = None + EqualsRange = None }); Ident d], [(5,15--5,16)], (4,4--5,18)), (3,6--5,47)), (3,0--5,47)), (3,0--5,47))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 05.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 05.fs.bsl index 08008766b4d..d93e009f5d7 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 05.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 05.fs.bsl @@ -34,9 +34,11 @@ ImplFile { YieldOrReturnKeyword = (3,23--3,29) }), (3,21--3,33)), (3,15--3,33)), [], ImplicitZero (3,33--3,33), (3,0--3,33), - { LetOrUseBangKeyword = (3,0--3,4) + { LetOrUseKeyword = (3,0--3,4) + InKeyword = None EqualsRange = Some (3,13--3,14) }), (2,0--3,33), - { LetOrUseBangKeyword = (2,0--2,4) + { LetOrUseKeyword = (2,0--2,4) + InKeyword = None EqualsRange = Some (2,11--2,12) }), (2,0--3,33))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--3,33), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 06.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 06.fs.bsl index 591ef048599..77623805e3a 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 06.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 06.fs.bsl @@ -34,9 +34,11 @@ ImplFile { YieldOrReturnKeyword = (3,23--3,29) }), (3,21--3,33)), (3,15--3,33)), [], ImplicitZero (3,33--3,33), (3,0--3,33), - { LetOrUseBangKeyword = (3,0--3,4) + { LetOrUseKeyword = (3,0--3,4) + InKeyword = None EqualsRange = Some (3,13--3,14) }), (2,0--3,33), - { LetOrUseBangKeyword = (2,0--2,4) + { LetOrUseKeyword = (2,0--2,4) + InKeyword = None EqualsRange = Some (2,11--2,12) }), (2,0--3,33))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--3,33), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 07.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 07.fs.bsl index 9493eb7270f..ec976f9d78d 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 07.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 07.fs.bsl @@ -25,7 +25,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (5,4--5,15), { YieldOrReturnKeyword = (5,4--5,10) }), (3,4--5,15), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,35--3,36) }), (2,6--7,1)), (2,0--7,1)), (2,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 08.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 08.fs.bsl index 62bf5bc63db..df08719e64d 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 08.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 08.fs.bsl @@ -24,7 +24,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (4,4--4,15), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,15), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,33--3,34) }), (2,6--6,1)), (2,0--6,1)), (2,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 09.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 09.fs.bsl index 0516dc630a8..f60b9363710 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 09.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 09.fs.bsl @@ -24,7 +24,8 @@ ImplFile YieldOrReturn ((false, true), Ident value, (4,4--4,16), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,16), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,23--3,24) }), (2,6--5,1)), (2,0--5,1)), (2,0--5,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 10.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 10.fs.bsl index f3758aff371..43d9f3e2fe9 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 10.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 10.fs.bsl @@ -22,7 +22,8 @@ ImplFile YieldOrReturn ((false, true), Ident value, (4,4--4,16), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,16), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,21--3,22) }), (2,6--5,1)), (2,0--5,1)), (2,0--5,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 11.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 11.fs.bsl index 096e0effc20..10b908ae70f 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 11.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 11.fs.bsl @@ -30,7 +30,8 @@ ImplFile YieldOrReturn ((false, true), Ident value, (4,4--4,16), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,16), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,35--3,36) }), (2,6--5,1)), (2,0--5,1)), (2,0--5,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 12.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 12.fs.bsl index b274a8880f3..129c53c43f2 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 12.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 12.fs.bsl @@ -28,7 +28,8 @@ ImplFile YieldOrReturn ((false, true), Ident value, (4,4--4,16), { YieldOrReturnKeyword = (4,4--4,10) }), (3,4--4,16), - { LetOrUseBangKeyword = (3,4--3,8) + { LetOrUseKeyword = (3,4--3,8) + InKeyword = None EqualsRange = Some (3,33--3,34) }), (2,6--5,1)), (2,0--5,1)), (2,0--5,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 14.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 14.fs.bsl index c4ed5ee643f..93a922eddab 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 14.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 14.fs.bsl @@ -55,7 +55,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,19--4,20) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 15.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 15.fs.bsl index 1a461ef4b3e..a199310f6a3 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 15.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 15.fs.bsl @@ -36,7 +36,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (5,26--5,27) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 17.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 17.fs.bsl index 6f78c27dca1..25505e0b9e6 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 17.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 17.fs.bsl @@ -46,7 +46,8 @@ ImplFile (5,32--5,40), { YieldOrReturnKeyword = (5,32--5,38) }), (5,30--5,42)), (5,24--5,42)), [], ImplicitZero (5,42--5,42), (5,0--5,42), - { LetOrUseBangKeyword = (5,0--5,4) + { LetOrUseKeyword = (5,0--5,4) + InKeyword = None EqualsRange = Some (5,22--5,23) }), (5,0--5,42))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--5,42), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 18.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 18.fs.bsl index 8579d42db13..180faf48052 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 18.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 18.fs.bsl @@ -47,7 +47,8 @@ ImplFile (5,30--5,38), { YieldOrReturnKeyword = (5,30--5,36) }), (5,28--5,40)), (5,22--5,40)), [], ImplicitZero (5,40--5,40), (5,0--5,40), - { LetOrUseBangKeyword = (5,0--5,4) + { LetOrUseKeyword = (5,0--5,4) + InKeyword = None EqualsRange = Some (5,20--5,21) }), (5,0--5,40))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--5,40), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 19.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 19.fs.bsl index 4ccac506d64..ecd65b24301 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 19.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 19.fs.bsl @@ -57,11 +57,13 @@ ImplFile YieldOrReturn ((false, true), Ident x, (6,4--6,12), { YieldOrReturnKeyword = (6,4--6,10) }), - (5,4--6,12), { LetOrUseBangKeyword = (5,4--5,8) + (5,4--6,12), { LetOrUseKeyword = (5,4--5,8) + InKeyword = None EqualsRange = Some (5,26--5,27) }), (4,4--6,12), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,6--7,1)), - (3,0--7,1)), (3,0--7,1))], + InKeyword = None + EqualsRange = Some (4,25--4,26) }), + (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--7,1), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang 20.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang 20.fs.bsl index e14813fde0c..c9d8cdb5267 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang 20.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang 20.fs.bsl @@ -60,11 +60,13 @@ ImplFile YieldOrReturn ((false, true), Ident x, (6,4--6,12), { YieldOrReturnKeyword = (6,4--6,10) }), - (5,4--6,12), { LetOrUseBangKeyword = (5,4--5,8) + (5,4--6,12), { LetOrUseKeyword = (5,4--5,8) + InKeyword = None EqualsRange = Some (5,24--5,25) }), (4,4--6,12), { LetOrUseKeyword = (4,4--4,7) - InKeyword = None }), (3,6--7,1)), - (3,0--7,1)), (3,0--7,1))], + InKeyword = None + EqualsRange = Some (4,23--4,24) }), + (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--7,1), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 01.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 01.fs.bsl index 0aa056d6da5..865c5a7883d 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 01.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 01.fs.bsl @@ -46,7 +46,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (6,4--6,14), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,18--4,19) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 02.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 02.fs.bsl index 0f5f06df777..ed100564aef 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 02.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 02.fs.bsl @@ -50,7 +50,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (6,4--6,14), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,20--4,21) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 03.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 03.fs.bsl index 9d127609634..8c41c87de16 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 03.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 03.fs.bsl @@ -47,7 +47,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (6,4--6,15), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,15), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,46--4,47) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 04.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 04.fs.bsl index 2377382104e..1ad08e47ec6 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 04.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 04.fs.bsl @@ -45,7 +45,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (6,4--6,15), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,15), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,44--4,45) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 05.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 05.fs.bsl index 2309e7f9490..5fb229546c6 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 05.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 05.fs.bsl @@ -46,7 +46,8 @@ ImplFile YieldOrReturn ((false, true), Ident name, (6,4--6,15), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,15), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,46--4,47) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 06.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 06.fs.bsl index e46cfc2ef7c..5354fd61d49 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 06.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 06.fs.bsl @@ -52,7 +52,8 @@ ImplFile (6,17--6,18)), Ident value, (6,11--6,18)), Ident value2, (6,11--6,25)), (6,4--6,25), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,25), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,23--4,24) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 07.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 07.fs.bsl index 6bc6a07abec..31b4888fba6 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 07.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 07.fs.bsl @@ -48,7 +48,8 @@ ImplFile (6,17--6,18)), Ident value, (6,11--6,18)), Ident value2, (6,11--6,25)), (6,4--6,25), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,25), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,21--4,22) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 08.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 08.fs.bsl index 7ca03b4f9e3..f04efe243af 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 08.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 08.fs.bsl @@ -65,7 +65,8 @@ ImplFile (6,17--6,18)), Ident value, (6,11--6,18)), Ident value2, (6,11--6,25)), (6,4--6,25), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,25), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,35--4,36) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 09.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 09.fs.bsl index 0233ea37538..1da61fcb395 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 09.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 09.fs.bsl @@ -60,7 +60,8 @@ ImplFile (6,17--6,18)), Ident value, (6,11--6,18)), Ident value2, (6,11--6,25)), (6,4--6,25), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,25), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,33--4,34) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 10.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 10.fs.bsl index 4c616752ce3..49476bb21ad 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 10.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 10.fs.bsl @@ -57,7 +57,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,23--4,24) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 11.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 11.fs.bsl index 4c4991234a3..7305918522c 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 11.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 11.fs.bsl @@ -54,7 +54,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,21--4,22) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 12.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 12.fs.bsl index ffb04e5db54..db63b5cdd31 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 12.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 12.fs.bsl @@ -46,7 +46,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,16--4,17) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 13.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 13.fs.bsl index b79f90358d2..8d94b1d4d5c 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 13.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 13.fs.bsl @@ -60,7 +60,8 @@ ImplFile YieldOrReturn ((false, true), Ident first, (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,42--4,43) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 14.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 14.fs.bsl index eaefd1aa4ef..795342f5742 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 14.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 14.fs.bsl @@ -54,7 +54,8 @@ ImplFile YieldOrReturn ((false, true), Ident first, (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,40--4,41) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 15.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 15.fs.bsl index e60943e9933..9fdf1440fc8 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 15.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 15.fs.bsl @@ -38,7 +38,8 @@ ImplFile (Atomic, false, Ident asyncInt, Const (Unit, (4,37--4,39)), (4,29--4,39)), [], ImplicitZero (4,39--4,39), (4,4--5,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,27--4,28) }); Ident y], [(5,15--5,16)], (4,4--5,18)), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 16.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 16.fs.bsl index d9f64778935..65d6bfa4f5d 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 16.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 16.fs.bsl @@ -62,7 +62,8 @@ ImplFile YieldOrReturn ((false, true), Const (Unit, (6,11--6,13)), (6,4--6,13), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,13), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,27--4,28) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 17.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 17.fs.bsl index f801b2d1319..ea88513f59c 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 17.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 17.fs.bsl @@ -65,7 +65,8 @@ ImplFile YieldOrReturn ((false, true), Const (Unit, (6,11--6,13)), (6,4--6,13), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,13), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,27--4,28) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 18.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 18.fs.bsl index 037d6651228..2b833c4e6dd 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 18.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed LetBang AndBang 18.fs.bsl @@ -56,7 +56,8 @@ ImplFile (6,13--6,14)), Ident x, (6,11--6,14)), Ident b, (6,11--6,16)), (6,4--6,16), { YieldOrReturnKeyword = (6,4--6,10) }), (4,4--6,16), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,23--4,24) }), (3,6--7,1)), (3,0--7,1)), (3,0--7,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 01.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 01.fs.bsl index a49e9a4abf3..68ffa0052e2 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 01.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 01.fs.bsl @@ -26,7 +26,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,18--4,19) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 02.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 02.fs.bsl index d402cdf754d..d108dbbdb26 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 02.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 02.fs.bsl @@ -28,7 +28,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,20--4,21) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 03.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 03.fs.bsl index a3eda56c6e0..7166b37a4b0 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 03.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 03.fs.bsl @@ -34,9 +34,11 @@ ImplFile { YieldOrReturnKeyword = (4,23--4,29) }), (4,21--4,33)), (4,15--4,33)), [], ImplicitZero (4,33--4,33), (4,0--4,33), - { LetOrUseBangKeyword = (4,0--4,4) + { LetOrUseKeyword = (4,0--4,4) + InKeyword = None EqualsRange = Some (4,13--4,14) }), (3,0--4,33), - { LetOrUseBangKeyword = (3,0--3,4) + { LetOrUseKeyword = (3,0--3,4) + InKeyword = None EqualsRange = Some (3,11--3,12) }), (3,0--4,33))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--4,33), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 04.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 04.fs.bsl index 3bf8a0ce44c..6253c5c42c5 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 04.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 04.fs.bsl @@ -34,9 +34,11 @@ ImplFile { YieldOrReturnKeyword = (4,23--4,29) }), (4,21--4,33)), (4,15--4,33)), [], ImplicitZero (4,33--4,33), (4,0--4,33), - { LetOrUseBangKeyword = (4,0--4,4) + { LetOrUseKeyword = (4,0--4,4) + InKeyword = None EqualsRange = Some (4,13--4,14) }), (3,0--4,33), - { LetOrUseBangKeyword = (3,0--3,4) + { LetOrUseKeyword = (3,0--3,4) + InKeyword = None EqualsRange = Some (3,11--3,12) }), (3,0--4,33))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--4,33), { LeadingKeyword = Module (1,0--1,6) })], (true, true), diff --git a/tests/service/data/SyntaxTree/SynType/Typed UseBang 05.fs.bsl b/tests/service/data/SyntaxTree/SynType/Typed UseBang 05.fs.bsl index 9042c097425..02b8514ab6a 100644 --- a/tests/service/data/SyntaxTree/SynType/Typed UseBang 05.fs.bsl +++ b/tests/service/data/SyntaxTree/SynType/Typed UseBang 05.fs.bsl @@ -25,7 +25,8 @@ ImplFile YieldOrReturn ((false, true), Ident res, (5,4--5,14), { YieldOrReturnKeyword = (5,4--5,10) }), (4,4--5,14), - { LetOrUseBangKeyword = (4,4--4,8) + { LetOrUseKeyword = (4,4--4,8) + InKeyword = None EqualsRange = Some (4,14--4,15) }), (3,6--6,1)), (3,0--6,1)), (3,0--6,1))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, From adfa81221519f6b807dd9f40414e92e85ff2fb0b Mon Sep 17 00:00:00 2001 From: edgargonzalez Date: Sat, 2 Aug 2025 12:48:29 +0200 Subject: [PATCH 09/10] remove unused mEquals --- src/Compiler/SyntaxTree/ParseHelpers.fs | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/Compiler/SyntaxTree/ParseHelpers.fs b/src/Compiler/SyntaxTree/ParseHelpers.fs index 5d3f91c4912..64b525e1afd 100644 --- a/src/Compiler/SyntaxTree/ParseHelpers.fs +++ b/src/Compiler/SyntaxTree/ParseHelpers.fs @@ -1106,11 +1106,6 @@ let mkLetExpression match decls with | SynBinding(trivia = trivia) :: _ -> trivia.LeadingKeyword.Range | _ -> range0 - - let mEquals = - match decls with - | SynBinding(trivia = trivia) :: _ -> trivia.EqualsRange - | _ -> None let mEquals = match decls with From 5fa187d045283a61d775e56ca8418ef02838671f Mon Sep 17 00:00:00 2001 From: edgargonzalez Date: Sat, 2 Aug 2025 13:47:38 +0200 Subject: [PATCH 10/10] update baselines --- ...ervice.SurfaceArea.netstandard20.debug.bsl | 34 +++++++------------ ...vice.SurfaceArea.netstandard20.release.bsl | 18 ++++------ 2 files changed, 18 insertions(+), 34 deletions(-) diff --git a/tests/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.SurfaceArea.netstandard20.debug.bsl b/tests/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.SurfaceArea.netstandard20.debug.bsl index 4f1bda7afd1..4275cefb8be 100644 --- a/tests/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.SurfaceArea.netstandard20.debug.bsl +++ b/tests/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.SurfaceArea.netstandard20.debug.bsl @@ -7229,8 +7229,8 @@ FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Syntax.SynExpr get_ FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Syntax.SynExpr rhs FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Syntax.SynPat get_pat() FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Syntax.SynPat pat -FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia get_trivia() -FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia trivia +FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia get_trivia() +FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia trivia FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Text.Range get_range() FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Text.Range range FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExprAndBang] andBangs @@ -7760,7 +7760,7 @@ FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewJoinIn(FSharp. FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLambda(Boolean, Boolean, FSharp.Compiler.Syntax.SynSimplePats, FSharp.Compiler.Syntax.SynExpr, Microsoft.FSharp.Core.FSharpOption`1[System.Tuple`2[Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynPat],FSharp.Compiler.Syntax.SynExpr]], FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLazy(FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLetOrUse(Boolean, Boolean, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynBinding], FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia) -FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLetOrUseBang(FSharp.Compiler.Syntax.DebugPointAtBinding, Boolean, Boolean, FSharp.Compiler.Syntax.SynPat, FSharp.Compiler.Syntax.SynExpr, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExprAndBang], FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia) +FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLetOrUseBang(FSharp.Compiler.Syntax.DebugPointAtBinding, Boolean, Boolean, FSharp.Compiler.Syntax.SynPat, FSharp.Compiler.Syntax.SynExpr, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExprAndBang], FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLibraryOnlyILAssembly(System.Object, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynType], Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExpr], Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynType], FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLibraryOnlyStaticOptimization(Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynStaticOptimizationConstraint], FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLibraryOnlyUnionCaseFieldGet(FSharp.Compiler.Syntax.SynExpr, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.Ident], Int32, FSharp.Compiler.Text.Range) @@ -10337,22 +10337,16 @@ FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia: Microsoft.FSharp.Core.FSharpOp FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_ArrowRange() FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia: System.String ToString() FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia: Void .ctor(Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia Zero -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia get_Zero() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: FSharp.Compiler.Text.Range LetOrUseBangKeyword -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: FSharp.Compiler.Text.Range get_LetOrUseBangKeyword() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] EqualsRange -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_EqualsRange() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: System.String ToString() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: Void .ctor(FSharp.Compiler.Text.Range, Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia Zero FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia get_Zero() FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: FSharp.Compiler.Text.Range LetOrUseKeyword FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: FSharp.Compiler.Text.Range get_LetOrUseKeyword() +FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] EqualsRange FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] InKeyword +FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_EqualsRange() FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_InKeyword() FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: System.String ToString() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Void .ctor(FSharp.Compiler.Text.Range, Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) +FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Void .ctor(FSharp.Compiler.Text.Range, Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range], Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) FSharp.Compiler.SyntaxTrivia.SynExprMatchBangTrivia: FSharp.Compiler.Text.Range MatchBangKeyword FSharp.Compiler.SyntaxTrivia.SynExprMatchBangTrivia: FSharp.Compiler.Text.Range WithKeyword FSharp.Compiler.SyntaxTrivia.SynExprMatchBangTrivia: FSharp.Compiler.Text.Range get_MatchBangKeyword() @@ -10837,22 +10831,18 @@ FSharp.Compiler.SyntaxTrivia.SynValSigTrivia: Microsoft.FSharp.Core.FSharpOption FSharp.Compiler.SyntaxTrivia.SynValSigTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_WithKeyword() FSharp.Compiler.SyntaxTrivia.SynValSigTrivia: System.String ToString() FSharp.Compiler.SyntaxTrivia.SynValSigTrivia: Void .ctor(FSharp.Compiler.SyntaxTrivia.SynLeadingKeyword, Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range], Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range], Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Nowarn: FSharp.Compiler.Text.Range Item2 -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Nowarn: FSharp.Compiler.Text.Range get_Item2() -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Nowarn: Microsoft.FSharp.Collections.FSharpList`1[System.Int32] get_warnNumbers() -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Nowarn: Microsoft.FSharp.Collections.FSharpList`1[System.Int32] warnNumbers +FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Nowarn: FSharp.Compiler.Text.Range Item +FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Nowarn: FSharp.Compiler.Text.Range get_Item() FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Tags: Int32 Nowarn FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Tags: Int32 Warnon -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Warnon: FSharp.Compiler.Text.Range Item2 -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Warnon: FSharp.Compiler.Text.Range get_Item2() -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Warnon: Microsoft.FSharp.Collections.FSharpList`1[System.Int32] get_warnNumbers() -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Warnon: Microsoft.FSharp.Collections.FSharpList`1[System.Int32] warnNumbers +FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Warnon: FSharp.Compiler.Text.Range Item +FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Warnon: FSharp.Compiler.Text.Range get_Item() FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: Boolean IsNowarn FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: Boolean IsWarnon FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: Boolean get_IsNowarn() FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: Boolean get_IsWarnon() -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia NewNowarn(Microsoft.FSharp.Collections.FSharpList`1[System.Int32], FSharp.Compiler.Text.Range) -FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia NewWarnon(Microsoft.FSharp.Collections.FSharpList`1[System.Int32], FSharp.Compiler.Text.Range) +FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia NewNowarn(FSharp.Compiler.Text.Range) +FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia NewWarnon(FSharp.Compiler.Text.Range) FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Nowarn FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Tags FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia: FSharp.Compiler.SyntaxTrivia.WarnDirectiveTrivia+Warnon diff --git a/tests/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.SurfaceArea.netstandard20.release.bsl b/tests/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.SurfaceArea.netstandard20.release.bsl index 703e5029e32..4275cefb8be 100644 --- a/tests/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.SurfaceArea.netstandard20.release.bsl +++ b/tests/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.SurfaceArea.netstandard20.release.bsl @@ -7229,8 +7229,8 @@ FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Syntax.SynExpr get_ FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Syntax.SynExpr rhs FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Syntax.SynPat get_pat() FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Syntax.SynPat pat -FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia get_trivia() -FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia trivia +FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia get_trivia() +FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia trivia FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Text.Range get_range() FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: FSharp.Compiler.Text.Range range FSharp.Compiler.Syntax.SynExpr+LetOrUseBang: Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExprAndBang] andBangs @@ -7760,7 +7760,7 @@ FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewJoinIn(FSharp. FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLambda(Boolean, Boolean, FSharp.Compiler.Syntax.SynSimplePats, FSharp.Compiler.Syntax.SynExpr, Microsoft.FSharp.Core.FSharpOption`1[System.Tuple`2[Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynPat],FSharp.Compiler.Syntax.SynExpr]], FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLazy(FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLetOrUse(Boolean, Boolean, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynBinding], FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia) -FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLetOrUseBang(FSharp.Compiler.Syntax.DebugPointAtBinding, Boolean, Boolean, FSharp.Compiler.Syntax.SynPat, FSharp.Compiler.Syntax.SynExpr, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExprAndBang], FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia) +FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLetOrUseBang(FSharp.Compiler.Syntax.DebugPointAtBinding, Boolean, Boolean, FSharp.Compiler.Syntax.SynPat, FSharp.Compiler.Syntax.SynExpr, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExprAndBang], FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLibraryOnlyILAssembly(System.Object, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynType], Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExpr], Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynType], FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLibraryOnlyStaticOptimization(Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynStaticOptimizationConstraint], FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewLibraryOnlyUnionCaseFieldGet(FSharp.Compiler.Syntax.SynExpr, Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.Ident], Int32, FSharp.Compiler.Text.Range) @@ -10337,22 +10337,16 @@ FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia: Microsoft.FSharp.Core.FSharpOp FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_ArrowRange() FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia: System.String ToString() FSharp.Compiler.SyntaxTrivia.SynExprLambdaTrivia: Void .ctor(Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia Zero -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia get_Zero() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: FSharp.Compiler.Text.Range LetOrUseBangKeyword -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: FSharp.Compiler.Text.Range get_LetOrUseBangKeyword() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] EqualsRange -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_EqualsRange() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: System.String ToString() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseBangTrivia: Void .ctor(FSharp.Compiler.Text.Range, Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia Zero FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia get_Zero() FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: FSharp.Compiler.Text.Range LetOrUseKeyword FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: FSharp.Compiler.Text.Range get_LetOrUseKeyword() +FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] EqualsRange FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] InKeyword +FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_EqualsRange() FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_InKeyword() FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: System.String ToString() -FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Void .ctor(FSharp.Compiler.Text.Range, Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) +FSharp.Compiler.SyntaxTrivia.SynExprLetOrUseTrivia: Void .ctor(FSharp.Compiler.Text.Range, Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range], Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) FSharp.Compiler.SyntaxTrivia.SynExprMatchBangTrivia: FSharp.Compiler.Text.Range MatchBangKeyword FSharp.Compiler.SyntaxTrivia.SynExprMatchBangTrivia: FSharp.Compiler.Text.Range WithKeyword FSharp.Compiler.SyntaxTrivia.SynExprMatchBangTrivia: FSharp.Compiler.Text.Range get_MatchBangKeyword()