diff --git a/docs/release-notes/.FSharp.Compiler.Service/8.0.300.md b/docs/release-notes/.FSharp.Compiler.Service/8.0.300.md index 652a7971f2d..041b07bfec6 100644 --- a/docs/release-notes/.FSharp.Compiler.Service/8.0.300.md +++ b/docs/release-notes/.FSharp.Compiler.Service/8.0.300.md @@ -44,6 +44,7 @@ * Parser: more 'as' pattern recovery ([PR #16837](https://github.com/dotnet/fsharp/pull/16837)) * Add extended data for `DefinitionsInSigAndImplNotCompatibleAbbreviationsDiffer` (FS0318). ([PR #16811](https://github.com/dotnet/fsharp/pull/16811))) * Checker/patterns: recover on unresolved long identifiers ([PR #16842](https://github.com/dotnet/fsharp/pull/16842)) +* SynExprSequentialTrivia ([Issue #16914](https://github.com/dotnet/fsharp/issues/16914), [PR #16981](https://github.com/dotnet/fsharp/pull/16981)) ### Changed diff --git a/src/Compiler/Checking/CheckComputationExpressions.fs b/src/Compiler/Checking/CheckComputationExpressions.fs index e13e56f2c4b..3384b247b1f 100644 --- a/src/Compiler/Checking/CheckComputationExpressions.fs +++ b/src/Compiler/Checking/CheckComputationExpressions.fs @@ -205,7 +205,7 @@ let (|SimpleSemicolonSequence|_|) cenv acceptDeprecated cexpr = let rec TryGetSimpleSemicolonSequenceOfComprehension expr acc = match expr with - | SynExpr.Sequential(_, true, e1, e2, _) -> + | SynExpr.Sequential(isTrueSeq = true; expr1 = e1; expr2 = e2) -> if IsSimpleSemicolonSequenceElement e1 then TryGetSimpleSemicolonSequenceOfComprehension e2 (e1 :: acc) else @@ -752,8 +752,14 @@ let TcComputationExpression (cenv: cenv) env (overallTy: OverallTy) tpenv (mWhol let (|ForEachThen|_|) synExpr = match synExpr with - | SynExpr.ForEach(_spFor, _spIn, SeqExprOnly false, isFromSource, pat1, expr1, SynExpr.Sequential(_, true, clause, rest, _), _) -> - Some(isFromSource, pat1, expr1, clause, rest) + | SynExpr.ForEach(_spFor, + _spIn, + SeqExprOnly false, + isFromSource, + pat1, + expr1, + SynExpr.Sequential(isTrueSeq = true; expr1 = clause; expr2 = rest), + _) -> Some(isFromSource, pat1, expr1, clause, rest) | _ -> None let (|CustomOpId|_|) predicate synExpr = @@ -998,7 +1004,7 @@ let TcComputationExpression (cenv: cenv) env (overallTy: OverallTy) tpenv (mWhol let (|OptionalSequential|) e = match e with - | SynExpr.Sequential(_sp, true, dataComp1, dataComp2, _) -> (dataComp1, Some dataComp2) + | SynExpr.Sequential(debugPoint = _sp; isTrueSeq = true; expr1 = dataComp1; expr2 = dataComp2) -> (dataComp1, Some dataComp2) | _ -> (e, None) // "cexpr; cexpr" is treated as builder.Combine(cexpr1, cexpr1) @@ -1233,7 +1239,14 @@ let TcComputationExpression (cenv: cenv) env (overallTy: OverallTy) tpenv (mWhol // 2. incompatible types: int and string // with SynExpr.ArbitraryAfterError we have only first one let wrapInArbErrSequence l caption = - SynExpr.Sequential(DebugPointAtSequential.SuppressNeither, true, l, (arbExpr (caption, l.Range.EndRange)), l.Range) + SynExpr.Sequential( + DebugPointAtSequential.SuppressNeither, + true, + l, + (arbExpr (caption, l.Range.EndRange)), + l.Range, + SynExprSequentialTrivia.Zero + ) let mkOverallExprGivenVarSpaceExpr, varSpaceInner = @@ -1529,7 +1542,14 @@ let TcComputationExpression (cenv: cenv) env (overallTy: OverallTy) tpenv (mWhol SynExpr.While( DebugPointAtWhile.No, SynExpr.Ident idCond, - SynExpr.Sequential(DebugPointAtSequential.SuppressBoth, true, innerComp, bindCondExpr, mWhile), + SynExpr.Sequential( + DebugPointAtSequential.SuppressBoth, + true, + innerComp, + bindCondExpr, + mWhile, + SynExprSequentialTrivia.Zero + ), mOrig ) @@ -1658,7 +1678,7 @@ let TcComputationExpression (cenv: cenv) env (overallTy: OverallTy) tpenv (mWhol // Now run the consumeCustomOpClauses Some(consumeCustomOpClauses q varSpace dataCompPriorToOp comp false mClause) - | SynExpr.Sequential(sp, true, innerComp1, innerComp2, m) -> + | SynExpr.Sequential(sp, true, innerComp1, innerComp2, m, _) -> // Check for 'where x > y' and other mis-applications of infix operators. If detected, give a good error message, and just ignore innerComp1 if isQuery && checkForBinaryApp innerComp1 then @@ -1761,7 +1781,7 @@ let TcComputationExpression (cenv: cenv) env (overallTy: OverallTy) tpenv (mWhol SynExpr.SequentialOrImplicitYield(sp, innerComp1, holeFill, combineExpr, m) else - SynExpr.Sequential(sp, true, innerComp1, holeFill, m) + SynExpr.Sequential(sp, true, innerComp1, holeFill, m, SynExprSequentialTrivia.Zero) translatedCtxt fillExpr) ) @@ -2643,7 +2663,14 @@ let TcComputationExpression (cenv: cenv) env (overallTy: OverallTy) tpenv (mWhol comp.Range ) else - SynExpr.Sequential(DebugPointAtSequential.SuppressExpr, true, comp, holeFill, comp.Range) + SynExpr.Sequential( + DebugPointAtSequential.SuppressExpr, + true, + comp, + holeFill, + comp.Range, + SynExprSequentialTrivia.Zero + ) translatedCtxt fillExpr) @@ -2772,14 +2799,14 @@ let TcComputationExpression (cenv: cenv) env (overallTy: OverallTy) tpenv (mWhol Some(varSpaceExpr, Some(innerComp, mClause)) - | SynExpr.Sequential(sp, true, innerComp1, innerComp2, m) -> + | SynExpr.Sequential(sp, true, innerComp1, innerComp2, m, trivia) -> // Check the first part isn't a computation expression construct if isSimpleExpr innerComp1 then // Check the second part is a simple return match convertSimpleReturnToExpr varSpace innerComp2 with | None -> None - | Some(innerExpr2, optionalCont) -> Some(SynExpr.Sequential(sp, true, innerComp1, innerExpr2, m), optionalCont) + | Some(innerExpr2, optionalCont) -> Some(SynExpr.Sequential(sp, true, innerComp1, innerExpr2, m, trivia), optionalCont) else None @@ -2798,7 +2825,7 @@ let TcComputationExpression (cenv: cenv) env (overallTy: OverallTy) tpenv (mWhol | SynExpr.ImplicitZero _ -> false | OptionalSequential(JoinOrGroupJoinOrZipClause _, _) -> false | OptionalSequential(CustomOperationClause _, _) -> false - | SynExpr.Sequential(_, _, innerComp1, innerComp2, _) -> isSimpleExpr innerComp1 && isSimpleExpr innerComp2 + | SynExpr.Sequential(expr1 = innerComp1; expr2 = innerComp2) -> isSimpleExpr innerComp1 && isSimpleExpr innerComp2 | SynExpr.IfThenElse(thenExpr = thenComp; elseExpr = elseCompOpt) -> isSimpleExpr thenComp && (match elseCompOpt with @@ -3122,7 +3149,7 @@ let TcSequenceExpression (cenv: cenv) env tpenv comp (overallTy: OverallTy) m = | SynExpr.DoBang(_rhsExpr, m) -> error (Error(FSComp.SR.tcDoBangIllegalInSequenceExpression (), m)) - | SynExpr.Sequential(sp, true, innerComp1, innerComp2, m) -> + | SynExpr.Sequential(sp, true, innerComp1, innerComp2, m, _) -> let env1 = { env with eIsControlFlow = diff --git a/src/Compiler/Checking/CheckExpressions.fs b/src/Compiler/Checking/CheckExpressions.fs index 06de913a461..4f7b56ebf11 100644 --- a/src/Compiler/Checking/CheckExpressions.fs +++ b/src/Compiler/Checking/CheckExpressions.fs @@ -5795,7 +5795,7 @@ and TcExprUndelayed (cenv: cenv) (overallTy: OverallTy) env tpenv (synExpr: SynE let _, tpenv = suppressErrorReporting (fun () -> TcExpr cenv overallTy env tpenv expr1) mkDefault(m, overallTy.Commit), tpenv - | SynExpr.Sequential (sp, dir, synExpr1, synExpr2, m) -> + | SynExpr.Sequential (sp, dir, synExpr1, synExpr2, m, _) -> TcExprSequential cenv overallTy env tpenv (synExpr, sp, dir, synExpr1, synExpr2, m) // Used to implement the type-directed 'implicit yield' rule for computation expressions @@ -10337,7 +10337,7 @@ and TcLinearExprs bodyChecker cenv env overallTy tpenv isCompExpr synExpr cont = let g = cenv.g match synExpr with - | SynExpr.Sequential (sp, true, expr1, expr2, m) when not isCompExpr -> + | SynExpr.Sequential (sp, true, expr1, expr2, m, _) when not isCompExpr -> let expr1R, _ = let env1 = { env with eIsControlFlow = (match sp with | DebugPointAtSequential.SuppressNeither | DebugPointAtSequential.SuppressExpr -> true | _ -> false) } TcStmtThatCantBeCtorBody cenv env1 tpenv expr1 diff --git a/src/Compiler/Interactive/fsi.fs b/src/Compiler/Interactive/fsi.fs index a6ea4f1867e..db33a53ee93 100644 --- a/src/Compiler/Interactive/fsi.fs +++ b/src/Compiler/Interactive/fsi.fs @@ -4258,7 +4258,14 @@ type FsiInteractionProcessor let m = expr.Range // Make this into "(); expr" to suppress generalization and compilation-as-function let exprWithSeq = - SynExpr.Sequential(DebugPointAtSequential.SuppressExpr, true, SynExpr.Const(SynConst.Unit, m.StartRange), expr, m) + SynExpr.Sequential( + DebugPointAtSequential.SuppressExpr, + true, + SynExpr.Const(SynConst.Unit, m.StartRange), + expr, + m, + SynExprSequentialTrivia.Zero + ) ExecuteParsedExpressionOnMainThread(ctok, diagnosticsLogger, exprWithSeq, istate)) |> commitResult diff --git a/src/Compiler/Service/FSharpParseFileResults.fs b/src/Compiler/Service/FSharpParseFileResults.fs index baea32da816..883c624804c 100644 --- a/src/Compiler/Service/FSharpParseFileResults.fs +++ b/src/Compiler/Service/FSharpParseFileResults.fs @@ -96,7 +96,7 @@ type FSharpParseFileResults(diagnostics: FSharpDiagnostic[], input: ParsedInput, match expr with // This lets us dive into subexpressions that may contain the binding we're after - | SynExpr.Sequential(_, _, expr1, expr2, _) -> + | SynExpr.Sequential(expr1 = expr1; expr2 = expr2) -> if rangeContainsPos expr1.Range pos then walkBinding expr1 workingRange else @@ -714,7 +714,7 @@ type FSharpParseFileResults(diagnostics: FSharpDiagnostic[], input: ParsedInput, yield! walkFinallySeqPt spFinally | SynExpr.SequentialOrImplicitYield(spSeq, e1, e2, _, _) - | SynExpr.Sequential(spSeq, _, e1, e2, _) -> + | SynExpr.Sequential(debugPoint = spSeq; expr1 = e1; expr2 = e2) -> let implicit1 = match spSeq with | DebugPointAtSequential.SuppressExpr diff --git a/src/Compiler/Service/ServiceParsedInputOps.fs b/src/Compiler/Service/ServiceParsedInputOps.fs index d739526a025..3f379c0f8b6 100644 --- a/src/Compiler/Service/ServiceParsedInputOps.fs +++ b/src/Compiler/Service/ServiceParsedInputOps.fs @@ -263,8 +263,8 @@ module ParsedInput = let rec collect expr acc = match expr with - | SynExpr.Sequential(_, _, e1, (SynExpr.Sequential _ as e2), _) -> collect e2 (e1 :: acc) - | SynExpr.Sequential(_, _, e1, e2, _) -> e2 :: e1 :: acc + | SynExpr.Sequential(expr1 = e1; expr2 = (SynExpr.Sequential _ as e2)) -> collect e2 (e1 :: acc) + | SynExpr.Sequential(expr1 = e1; expr2 = e2) -> e2 :: e1 :: acc | _ -> acc match collect expr [] with diff --git a/src/Compiler/Service/ServiceStructure.fs b/src/Compiler/Service/ServiceStructure.fs index e2e8e4c20bd..1d0f7c7f8ec 100644 --- a/src/Compiler/Service/ServiceStructure.fs +++ b/src/Compiler/Service/ServiceStructure.fs @@ -337,7 +337,7 @@ module Structure = parseExpr argExpr parseExpr funcExpr - | SynExpr.Sequential(_, _, e1, e2, _) -> + | SynExpr.Sequential(expr1 = e1; expr2 = e2) -> parseExpr e1 parseExpr e2 diff --git a/src/Compiler/SyntaxTree/SyntaxTree.fs b/src/Compiler/SyntaxTree/SyntaxTree.fs index a97976bee5c..69cd067ddfe 100644 --- a/src/Compiler/SyntaxTree/SyntaxTree.fs +++ b/src/Compiler/SyntaxTree/SyntaxTree.fs @@ -630,7 +630,13 @@ type SynExpr = | Lazy of expr: SynExpr * range: range - | Sequential of debugPoint: DebugPointAtSequential * isTrueSeq: bool * expr1: SynExpr * expr2: SynExpr * range: range + | Sequential of + debugPoint: DebugPointAtSequential * + isTrueSeq: bool * + expr1: SynExpr * + expr2: SynExpr * + range: range * + trivia: SynExprSequentialTrivia | IfThenElse of ifExpr: SynExpr * @@ -835,9 +841,9 @@ type SynExpr = match e with // these are better than just .Range, and also commonly applicable inside queries | SynExpr.Paren(_, m, _, _) -> m - | SynExpr.Sequential(_, _, e1, _, _) - | SynExpr.SequentialOrImplicitYield(_, e1, _, _, _) - | SynExpr.App(_, _, e1, _, _) -> e1.RangeOfFirstPortion + | SynExpr.Sequential(expr1 = e1) + | SynExpr.SequentialOrImplicitYield(expr1 = e1) + | SynExpr.App(funcExpr = e1) -> e1.RangeOfFirstPortion | SynExpr.ForEach(pat = pat; range = r) -> let e = (pat.Range: range).Start withEnd e r diff --git a/src/Compiler/SyntaxTree/SyntaxTree.fsi b/src/Compiler/SyntaxTree/SyntaxTree.fsi index fa88b48004d..363ddf55a1d 100644 --- a/src/Compiler/SyntaxTree/SyntaxTree.fsi +++ b/src/Compiler/SyntaxTree/SyntaxTree.fsi @@ -754,7 +754,8 @@ type SynExpr = isTrueSeq: bool * expr1: SynExpr * expr2: SynExpr * - range: range + range: range * + trivia: SynExprSequentialTrivia /// F# syntax: if expr then expr /// F# syntax: if expr then expr else expr diff --git a/src/Compiler/SyntaxTree/SyntaxTreeOps.fs b/src/Compiler/SyntaxTree/SyntaxTreeOps.fs index f775e47de8c..f2089e863e8 100644 --- a/src/Compiler/SyntaxTree/SyntaxTreeOps.fs +++ b/src/Compiler/SyntaxTree/SyntaxTreeOps.fs @@ -942,7 +942,7 @@ let rec synExprContainsError inpExpr = | SynExpr.TryFinally(tryExpr = e1; finallyExpr = e2) -> walkExpr e1 || walkExpr e2 - | SynExpr.Sequential(_, _, e1, e2, _) -> walkExpr e1 || walkExpr e2 + | SynExpr.Sequential(expr1 = e1; expr2 = e2) -> walkExpr e1 || walkExpr e2 | SynExpr.SequentialOrImplicitYield(_, e1, e2, _, _) -> walkExpr e1 || walkExpr e2 diff --git a/src/Compiler/SyntaxTree/SyntaxTrivia.fs b/src/Compiler/SyntaxTree/SyntaxTrivia.fs index 7330ac9b695..82c581520b4 100644 --- a/src/Compiler/SyntaxTree/SyntaxTrivia.fs +++ b/src/Compiler/SyntaxTree/SyntaxTrivia.fs @@ -115,6 +115,14 @@ type SynExprMatchBangTrivia = [] type SynExprAnonRecdTrivia = { OpeningBraceRange: range } +[] +type SynExprSequentialTrivia = + { + SeparatorRange: range option + } + + static member val Zero = { SeparatorRange = None } + [] type SynMatchClauseTrivia = { diff --git a/src/Compiler/SyntaxTree/SyntaxTrivia.fsi b/src/Compiler/SyntaxTree/SyntaxTrivia.fsi index 137f5432803..79c7903e78c 100644 --- a/src/Compiler/SyntaxTree/SyntaxTrivia.fsi +++ b/src/Compiler/SyntaxTree/SyntaxTrivia.fsi @@ -175,6 +175,17 @@ type SynExprAnonRecdTrivia = OpeningBraceRange: range } +/// Represents additional information for SynExpr.Sequential +[] +type SynExprSequentialTrivia = + { + /// The syntax range of the `;` token. + /// Could also be the `then` keyword. + SeparatorRange: range option + } + + static member Zero: SynExprSequentialTrivia + /// Represents additional information for SynMatchClause [] type SynMatchClauseTrivia = diff --git a/src/Compiler/pars.fsy b/src/Compiler/pars.fsy index b1b4f43a473..1c77af1e1a3 100644 --- a/src/Compiler/pars.fsy +++ b/src/Compiler/pars.fsy @@ -3895,7 +3895,8 @@ typedSequentialExprEOF: sequentialExpr: | declExpr seps sequentialExpr - { SynExpr.Sequential(DebugPointAtSequential.SuppressNeither, true, $1, $3, unionRanges $1.Range $3.Range) } + { let trivia = { SeparatorRange = $2 } + SynExpr.Sequential(DebugPointAtSequential.SuppressNeither, true, $1, $3, unionRanges $1.Range $3.Range, trivia) } | declExpr seps { $1 } @@ -3904,10 +3905,12 @@ sequentialExpr: { $1 } | declExpr THEN sequentialExpr %prec prec_then_before - { SynExpr.Sequential(DebugPointAtSequential.SuppressNeither, false, $1, $3, unionRanges $1.Range $3.Range) } + { let trivia = { SeparatorRange = Some (rhs parseState 2) } + SynExpr.Sequential(DebugPointAtSequential.SuppressNeither, false, $1, $3, unionRanges $1.Range $3.Range, trivia) } | declExpr OTHEN OBLOCKBEGIN typedSequentialExpr oblockend %prec prec_then_before - { SynExpr.Sequential(DebugPointAtSequential.SuppressNeither, false, $1, $4, unionRanges $1.Range $4.Range) } + { let trivia = { SeparatorRange = Some (rhs parseState 2) } + SynExpr.Sequential(DebugPointAtSequential.SuppressNeither, false, $1, $4, unionRanges $1.Range $4.Range, trivia) } | hardwhiteLetBindings %prec prec_args_error { let hwlb, m, mIn = $1 @@ -6658,10 +6661,10 @@ opt_topSeparators: /* Seprators in either #light or non-#light */ seps: - | OBLOCKSEP { } - | SEMICOLON { } - | OBLOCKSEP SEMICOLON { } - | SEMICOLON OBLOCKSEP { } + | OBLOCKSEP { None } + | SEMICOLON { Some (rhs parseState 1) } + | OBLOCKSEP SEMICOLON { Some (rhs parseState 2) } + | SEMICOLON OBLOCKSEP { Some (rhs parseState 1) } /* An 'end' that's optional only in #light, where an ODECLEND gets inserted, and explicit 'end's get converted to OEND */ declEnd: 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 aa70fc6ea34..6c8423483a0 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 @@ -6993,6 +6993,8 @@ FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Syntax.SynExpr expr1 FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Syntax.SynExpr expr2 FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Syntax.SynExpr get_expr1() FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Syntax.SynExpr get_expr2() +FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia get_trivia() +FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia trivia FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Text.Range get_range() FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Text.Range range FSharp.Compiler.Syntax.SynExpr+SequentialOrImplicitYield: FSharp.Compiler.Syntax.DebugPointAtSequential debugPoint @@ -7381,7 +7383,7 @@ FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewObjExpr(FSharp FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewParen(FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range], FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewQuote(FSharp.Compiler.Syntax.SynExpr, Boolean, FSharp.Compiler.Syntax.SynExpr, Boolean, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewRecord(Microsoft.FSharp.Core.FSharpOption`1[System.Tuple`5[FSharp.Compiler.Syntax.SynType,FSharp.Compiler.Syntax.SynExpr,FSharp.Compiler.Text.Range,Microsoft.FSharp.Core.FSharpOption`1[System.Tuple`2[FSharp.Compiler.Text.Range,Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Position]]],FSharp.Compiler.Text.Range]], Microsoft.FSharp.Core.FSharpOption`1[System.Tuple`2[FSharp.Compiler.Syntax.SynExpr,System.Tuple`2[FSharp.Compiler.Text.Range,Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Position]]]], Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExprRecordField], FSharp.Compiler.Text.Range) -FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewSequential(FSharp.Compiler.Syntax.DebugPointAtSequential, Boolean, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) +FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewSequential(FSharp.Compiler.Syntax.DebugPointAtSequential, Boolean, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewSequentialOrImplicitYield(FSharp.Compiler.Syntax.DebugPointAtSequential, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewSet(FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewTraitCall(FSharp.Compiler.Syntax.SynType, FSharp.Compiler.Syntax.SynMemberSig, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) @@ -9890,6 +9892,12 @@ FSharp.Compiler.SyntaxTrivia.SynExprMatchTrivia: FSharp.Compiler.Text.Range get_ FSharp.Compiler.SyntaxTrivia.SynExprMatchTrivia: FSharp.Compiler.Text.Range get_WithKeyword() FSharp.Compiler.SyntaxTrivia.SynExprMatchTrivia: System.String ToString() FSharp.Compiler.SyntaxTrivia.SynExprMatchTrivia: Void .ctor(FSharp.Compiler.Text.Range, FSharp.Compiler.Text.Range) +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia Zero +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia get_Zero() +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] SeparatorRange +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_SeparatorRange() +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: System.String ToString() +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: Void .ctor(Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) FSharp.Compiler.SyntaxTrivia.SynExprTryFinallyTrivia: FSharp.Compiler.Text.Range FinallyKeyword FSharp.Compiler.SyntaxTrivia.SynExprTryFinallyTrivia: FSharp.Compiler.Text.Range TryKeyword FSharp.Compiler.SyntaxTrivia.SynExprTryFinallyTrivia: FSharp.Compiler.Text.Range get_FinallyKeyword() 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 aa70fc6ea34..6c8423483a0 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 @@ -6993,6 +6993,8 @@ FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Syntax.SynExpr expr1 FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Syntax.SynExpr expr2 FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Syntax.SynExpr get_expr1() FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Syntax.SynExpr get_expr2() +FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia get_trivia() +FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia trivia FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Text.Range get_range() FSharp.Compiler.Syntax.SynExpr+Sequential: FSharp.Compiler.Text.Range range FSharp.Compiler.Syntax.SynExpr+SequentialOrImplicitYield: FSharp.Compiler.Syntax.DebugPointAtSequential debugPoint @@ -7381,7 +7383,7 @@ FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewObjExpr(FSharp FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewParen(FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range], FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewQuote(FSharp.Compiler.Syntax.SynExpr, Boolean, FSharp.Compiler.Syntax.SynExpr, Boolean, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewRecord(Microsoft.FSharp.Core.FSharpOption`1[System.Tuple`5[FSharp.Compiler.Syntax.SynType,FSharp.Compiler.Syntax.SynExpr,FSharp.Compiler.Text.Range,Microsoft.FSharp.Core.FSharpOption`1[System.Tuple`2[FSharp.Compiler.Text.Range,Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Position]]],FSharp.Compiler.Text.Range]], Microsoft.FSharp.Core.FSharpOption`1[System.Tuple`2[FSharp.Compiler.Syntax.SynExpr,System.Tuple`2[FSharp.Compiler.Text.Range,Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Position]]]], Microsoft.FSharp.Collections.FSharpList`1[FSharp.Compiler.Syntax.SynExprRecordField], FSharp.Compiler.Text.Range) -FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewSequential(FSharp.Compiler.Syntax.DebugPointAtSequential, Boolean, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) +FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewSequential(FSharp.Compiler.Syntax.DebugPointAtSequential, Boolean, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range, FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewSequentialOrImplicitYield(FSharp.Compiler.Syntax.DebugPointAtSequential, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewSet(FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) FSharp.Compiler.Syntax.SynExpr: FSharp.Compiler.Syntax.SynExpr NewTraitCall(FSharp.Compiler.Syntax.SynType, FSharp.Compiler.Syntax.SynMemberSig, FSharp.Compiler.Syntax.SynExpr, FSharp.Compiler.Text.Range) @@ -9890,6 +9892,12 @@ FSharp.Compiler.SyntaxTrivia.SynExprMatchTrivia: FSharp.Compiler.Text.Range get_ FSharp.Compiler.SyntaxTrivia.SynExprMatchTrivia: FSharp.Compiler.Text.Range get_WithKeyword() FSharp.Compiler.SyntaxTrivia.SynExprMatchTrivia: System.String ToString() FSharp.Compiler.SyntaxTrivia.SynExprMatchTrivia: Void .ctor(FSharp.Compiler.Text.Range, FSharp.Compiler.Text.Range) +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia Zero +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia get_Zero() +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] SeparatorRange +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range] get_SeparatorRange() +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: System.String ToString() +FSharp.Compiler.SyntaxTrivia.SynExprSequentialTrivia: Void .ctor(Microsoft.FSharp.Core.FSharpOption`1[FSharp.Compiler.Text.Range]) FSharp.Compiler.SyntaxTrivia.SynExprTryFinallyTrivia: FSharp.Compiler.Text.Range FinallyKeyword FSharp.Compiler.SyntaxTrivia.SynExprTryFinallyTrivia: FSharp.Compiler.Text.Range TryKeyword FSharp.Compiler.SyntaxTrivia.SynExprTryFinallyTrivia: FSharp.Compiler.Text.Range get_FinallyKeyword() diff --git a/tests/service/data/SyntaxTree/CodeComment/TripleSlashCommentShouldBeCapturedIfUsedInAnInvalidLocation.fs.bsl b/tests/service/data/SyntaxTree/CodeComment/TripleSlashCommentShouldBeCapturedIfUsedInAnInvalidLocation.fs.bsl index 85dd058c92d..b57381ca8e6 100644 --- a/tests/service/data/SyntaxTree/CodeComment/TripleSlashCommentShouldBeCapturedIfUsedInAnInvalidLocation.fs.bsl +++ b/tests/service/data/SyntaxTree/CodeComment/TripleSlashCommentShouldBeCapturedIfUsedInAnInvalidLocation.fs.bsl @@ -30,12 +30,13 @@ ImplFile ([op_Addition], [], [Some (OriginalNotation "+")]), None, (9,6--9,7)), Ident a, (9,4--9,7)), - Const (Int32 1, (9,8--9,9)), (9,4--9,9)), (8,4--9,9)), - (2,0--3,5), NoneAtLet, { LeadingKeyword = Let (3,0--3,3) - InlineKeyword = None - EqualsRange = Some (3,6--3,7) })], - (2,0--9,9))], PreXmlDocEmpty, [], None, (3,0--10,0), - { LeadingKeyword = None })], (true, true), + Const (Int32 1, (9,8--9,9)), (9,4--9,9)), (8,4--9,9), + { SeparatorRange = None }), (2,0--3,5), NoneAtLet, + { LeadingKeyword = Let (3,0--3,3) + InlineKeyword = None + EqualsRange = Some (3,6--3,7) })], (2,0--9,9))], + PreXmlDocEmpty, [], None, (3,0--10,0), { LeadingKeyword = None })], + (true, true), { ConditionalDirectives = [] CodeComments = [LineComment (4,4--4,40); LineComment (6,4--6,36); diff --git a/tests/service/data/SyntaxTree/Expression/Record - Field 07.fs.bsl b/tests/service/data/SyntaxTree/Expression/Record - Field 07.fs.bsl index 3e8728cf03d..58a717c0121 100644 --- a/tests/service/data/SyntaxTree/Expression/Record - Field 07.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/Record - Field 07.fs.bsl @@ -20,8 +20,8 @@ ImplFile SynLongIdent ([op_Equality], [], [Some (OriginalNotation "=")]), None, (4,4--4,5)), Ident B, (4,2--4,5)), - Const (Int32 1, (4,6--4,7)), (4,2--4,7)), (3,2--4,7)), - (3,0--4,9)), (3,0--4,9))], + Const (Int32 1, (4,6--4,7)), (4,2--4,7)), (3,2--4,7), + { SeparatorRange = None }), (3,0--4,9)), (3,0--4,9))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--4,9), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/Expression/Record - Field 10.fs.bsl b/tests/service/data/SyntaxTree/Expression/Record - Field 10.fs.bsl index 3a9538cfb4d..0b0379f5dbf 100644 --- a/tests/service/data/SyntaxTree/Expression/Record - Field 10.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/Record - Field 10.fs.bsl @@ -18,8 +18,8 @@ ImplFile SynLongIdent ([op_Equality], [], [Some (OriginalNotation "=")]), None, (4,4--4,5)), Ident B, (4,2--4,5)), - Const (Int32 1, (4,6--4,7)), (4,2--4,7)), (3,2--4,7)), - (3,0--4,9)), (3,0--4,9))], + Const (Int32 1, (4,6--4,7)), (4,2--4,7)), (3,2--4,7), + { SeparatorRange = None }), (3,0--4,9)), (3,0--4,9))], PreXmlDoc ((1,0), FSharp.Compiler.Xml.XmlDocCollector), [], None, (1,0--4,9), { LeadingKeyword = Module (1,0--1,6) })], (true, true), { ConditionalDirectives = [] diff --git a/tests/service/data/SyntaxTree/Expression/Sequential 01.fs b/tests/service/data/SyntaxTree/Expression/Sequential 01.fs new file mode 100644 index 00000000000..57bc94aaf98 --- /dev/null +++ b/tests/service/data/SyntaxTree/Expression/Sequential 01.fs @@ -0,0 +1 @@ +do a ; b diff --git a/tests/service/data/SyntaxTree/Expression/Sequential 01.fs.bsl b/tests/service/data/SyntaxTree/Expression/Sequential 01.fs.bsl new file mode 100644 index 00000000000..c42ed608ed2 --- /dev/null +++ b/tests/service/data/SyntaxTree/Expression/Sequential 01.fs.bsl @@ -0,0 +1,17 @@ +ImplFile + (ParsedImplFileInput + ("/root/Expression/Sequential 01.fs", false, + QualifiedNameOfFile Sequential 01, [], [], + [SynModuleOrNamespace + ([Sequential 01], false, AnonModule, + [Expr + (Do + (Sequential + (SuppressNeither, true, Ident a, Ident b, (1,3--1,8), + { SeparatorRange = Some (1,5--1,6) }), (1,0--1,8)), + (1,0--1,8))], PreXmlDocEmpty, [], None, (1,0--2,0), + { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + CodeComments = [] }, set [])) + +(1,0)-(2,0) parse warning The declarations in this file will be placed in an implicit module 'Sequential 01' based on the file name 'Sequential 01.fs'. However this is not a valid F# identifier, so the contents will not be accessible from other files. Consider renaming the file or adding a 'module' or 'namespace' declaration at the top of the file. diff --git a/tests/service/data/SyntaxTree/Expression/Sequential 02.fs b/tests/service/data/SyntaxTree/Expression/Sequential 02.fs new file mode 100644 index 00000000000..f5ce18867a2 --- /dev/null +++ b/tests/service/data/SyntaxTree/Expression/Sequential 02.fs @@ -0,0 +1 @@ +do a then b diff --git a/tests/service/data/SyntaxTree/Expression/Sequential 02.fs.bsl b/tests/service/data/SyntaxTree/Expression/Sequential 02.fs.bsl new file mode 100644 index 00000000000..7d58b85ed22 --- /dev/null +++ b/tests/service/data/SyntaxTree/Expression/Sequential 02.fs.bsl @@ -0,0 +1,17 @@ +ImplFile + (ParsedImplFileInput + ("/root/Expression/Sequential 02.fs", false, + QualifiedNameOfFile Sequential 02, [], [], + [SynModuleOrNamespace + ([Sequential 02], false, AnonModule, + [Expr + (Do + (Sequential + (SuppressNeither, false, Ident a, Ident b, (1,3--1,11), + { SeparatorRange = Some (1,5--1,9) }), (1,0--1,11)), + (1,0--1,11))], PreXmlDocEmpty, [], None, (1,0--2,0), + { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + CodeComments = [] }, set [])) + +(1,0)-(2,0) parse warning The declarations in this file will be placed in an implicit module 'Sequential 02' based on the file name 'Sequential 02.fs'. However this is not a valid F# identifier, so the contents will not be accessible from other files. Consider renaming the file or adding a 'module' or 'namespace' declaration at the top of the file. diff --git a/tests/service/data/SyntaxTree/Expression/Sequential 03.fs b/tests/service/data/SyntaxTree/Expression/Sequential 03.fs new file mode 100644 index 00000000000..a0bacd5d0ec --- /dev/null +++ b/tests/service/data/SyntaxTree/Expression/Sequential 03.fs @@ -0,0 +1 @@ +do a then begin b end diff --git a/tests/service/data/SyntaxTree/Expression/Sequential 03.fs.bsl b/tests/service/data/SyntaxTree/Expression/Sequential 03.fs.bsl new file mode 100644 index 00000000000..b04598b79fd --- /dev/null +++ b/tests/service/data/SyntaxTree/Expression/Sequential 03.fs.bsl @@ -0,0 +1,19 @@ +ImplFile + (ParsedImplFileInput + ("/root/Expression/Sequential 03.fs", false, + QualifiedNameOfFile Sequential 03, [], [], + [SynModuleOrNamespace + ([Sequential 03], false, AnonModule, + [Expr + (Do + (Sequential + (SuppressNeither, false, Ident a, + Paren + (Ident b, (1,10--1,15), Some (1,18--1,21), (1,10--1,21)), + (1,3--1,21), { SeparatorRange = Some (1,5--1,9) }), + (1,0--1,21)), (1,0--1,21))], PreXmlDocEmpty, [], None, + (1,0--2,0), { LeadingKeyword = None })], (true, true), + { ConditionalDirectives = [] + CodeComments = [] }, set [])) + +(1,0)-(2,0) parse warning The declarations in this file will be placed in an implicit module 'Sequential 03' based on the file name 'Sequential 03.fs'. However this is not a valid F# identifier, so the contents will not be accessible from other files. Consider renaming the file or adding a 'module' or 'namespace' declaration at the top of the file. diff --git a/tests/service/data/SyntaxTree/Expression/SynExprDoContainsTheRangeOfTheDoKeyword.fs.bsl b/tests/service/data/SyntaxTree/Expression/SynExprDoContainsTheRangeOfTheDoKeyword.fs.bsl index 98964bd7ecf..e33ddf8bde9 100644 --- a/tests/service/data/SyntaxTree/Expression/SynExprDoContainsTheRangeOfTheDoKeyword.fs.bsl +++ b/tests/service/data/SyntaxTree/Expression/SynExprDoContainsTheRangeOfTheDoKeyword.fs.bsl @@ -14,11 +14,11 @@ ImplFile Named (SynIdent (a, None), false, None, (2,4--2,5)), None, Sequential (SuppressNeither, true, Do (Ident foobar, (3,4--4,14)), - DoBang (Ident foobarBang, (5,4--6,18)), (3,4--6,18)), - (2,4--2,5), NoneAtLet, { LeadingKeyword = Let (2,0--2,3) - InlineKeyword = None - EqualsRange = Some (2,6--2,7) })], - (2,0--6,18))], PreXmlDocEmpty, [], None, (2,0--7,0), - { LeadingKeyword = None })], (true, true), - { ConditionalDirectives = [] - CodeComments = [] }, set [])) + DoBang (Ident foobarBang, (5,4--6,18)), (3,4--6,18), + { SeparatorRange = None }), (2,4--2,5), NoneAtLet, + { LeadingKeyword = Let (2,0--2,3) + InlineKeyword = None + EqualsRange = Some (2,6--2,7) })], (2,0--6,18))], + PreXmlDocEmpty, [], None, (2,0--7,0), { LeadingKeyword = None })], + (true, true), { ConditionalDirectives = [] + CodeComments = [] }, set [])) diff --git a/tests/service/data/SyntaxTree/MatchClause/RangeOfMultipleSynMatchClause.fs.bsl b/tests/service/data/SyntaxTree/MatchClause/RangeOfMultipleSynMatchClause.fs.bsl index d1be520bff7..84ce5019498 100644 --- a/tests/service/data/SyntaxTree/MatchClause/RangeOfMultipleSynMatchClause.fs.bsl +++ b/tests/service/data/SyntaxTree/MatchClause/RangeOfMultipleSynMatchClause.fs.bsl @@ -37,9 +37,10 @@ ImplFile SynLongIdent ([Infrastructure; ReportWarning], [(7,18--7,19)], [None; None]), None, (7,4--7,32)), Ident ex, - (7,4--7,35)), Ident None, (7,4--8,8)), (6,2--8,8), - Yes, { ArrowRange = Some (6,5--6,7) - BarRange = Some (6,0--6,1) }); + (7,4--7,35)), Ident None, (7,4--8,8), + { SeparatorRange = None }), (6,2--8,8), Yes, + { ArrowRange = Some (6,5--6,7) + BarRange = Some (6,0--6,1) }); SynMatchClause (Named (SynIdent (exx, None), false, None, (9,2--9,5)), None, Ident None, (9,2--10,8), Yes, diff --git a/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClause.fs.bsl b/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClause.fs.bsl index dce57b959f6..dfa2ad58587 100644 --- a/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClause.fs.bsl +++ b/tests/service/data/SyntaxTree/MatchClause/RangeOfSingleSynMatchClause.fs.bsl @@ -37,9 +37,10 @@ ImplFile SynLongIdent ([Infrastructure; ReportWarning], [(6,18--6,19)], [None; None]), None, (6,4--6,32)), Ident ex, - (6,4--6,35)), Ident None, (6,4--7,8)), (5,5--7,8), - Yes, { ArrowRange = Some (5,8--5,10) - BarRange = None })], (2,0--7,8), Yes (2,0--2,3), + (6,4--6,35)), Ident None, (6,4--7,8), + { SeparatorRange = None }), (5,5--7,8), Yes, + { ArrowRange = Some (5,8--5,10) + BarRange = None })], (2,0--7,8), Yes (2,0--2,3), Yes (5,0--5,4), { TryKeyword = (2,0--2,3) TryToWithRange = (2,0--5,4) WithKeyword = (5,0--5,4) diff --git a/tests/service/data/SyntaxTree/Member/SynTypeDefnWithStaticMemberWithGetset.fs.bsl b/tests/service/data/SyntaxTree/Member/SynTypeDefnWithStaticMemberWithGetset.fs.bsl index 7749a9c5784..33c1348b561 100644 --- a/tests/service/data/SyntaxTree/Member/SynTypeDefnWithStaticMemberWithGetset.fs.bsl +++ b/tests/service/data/SyntaxTree/Member/SynTypeDefnWithStaticMemberWithGetset.fs.bsl @@ -50,7 +50,8 @@ ImplFile [(5,47--5,48)], (5,35--5,50)), (5,34--5,35), Some (5,50--5,51), (5,34--5,51)), (5,22--5,51)), - Const (Int32 4, (5,53--5,54)), (5,22--5,54)), + Const (Int32 4, (5,53--5,54)), (5,22--5,54), + { SeparatorRange = Some (5,51--5,52) }), (5,13--5,19), NoneAtInvisible, { LeadingKeyword = StaticMember ((3,4--3,10), (3,11--3,17)) diff --git a/tests/service/data/SyntaxTree/Pattern/InHeadPattern.fs.bsl b/tests/service/data/SyntaxTree/Pattern/InHeadPattern.fs.bsl index d159480e120..13a1e99ea00 100644 --- a/tests/service/data/SyntaxTree/Pattern/InHeadPattern.fs.bsl +++ b/tests/service/data/SyntaxTree/Pattern/InHeadPattern.fs.bsl @@ -20,12 +20,13 @@ ImplFile (SuppressNeither, true, Const (Int32 4, (2,15--2,16)), Sequential (SuppressNeither, true, Const (Int32 5, (2,18--2,19)), - Const (Int32 6, (2,21--2,22)), (2,18--2,22)), - (2,15--2,22)), (2,13--2,24)), (2,4--2,10), - Yes (2,0--2,24), { LeadingKeyword = Let (2,0--2,3) - InlineKeyword = None - EqualsRange = Some (2,11--2,12) })], - (2,0--2,24))], PreXmlDocEmpty, [], None, (2,0--3,0), - { LeadingKeyword = None })], (true, true), - { ConditionalDirectives = [] - CodeComments = [] }, set [])) + Const (Int32 6, (2,21--2,22)), (2,18--2,22), + { SeparatorRange = Some (2,19--2,20) }), (2,15--2,22), + { SeparatorRange = Some (2,16--2,17) }), (2,13--2,24)), + (2,4--2,10), Yes (2,0--2,24), + { LeadingKeyword = Let (2,0--2,3) + InlineKeyword = None + EqualsRange = Some (2,11--2,12) })], (2,0--2,24))], + PreXmlDocEmpty, [], None, (2,0--3,0), { LeadingKeyword = None })], + (true, true), { ConditionalDirectives = [] + CodeComments = [] }, set [])) diff --git a/tests/service/data/SyntaxTree/Pattern/OperatorInSynPatLongIdent.fs.bsl b/tests/service/data/SyntaxTree/Pattern/OperatorInSynPatLongIdent.fs.bsl index f95f9ac0334..90a60008ec8 100644 --- a/tests/service/data/SyntaxTree/Pattern/OperatorInSynPatLongIdent.fs.bsl +++ b/tests/service/data/SyntaxTree/Pattern/OperatorInSynPatLongIdent.fs.bsl @@ -23,12 +23,13 @@ ImplFile (SuppressNeither, true, Const (Int32 1, (2,22--2,23)), Sequential (SuppressNeither, true, Const (Int32 2, (2,24--2,25)), - Const (Int32 4, (2,26--2,27)), (2,24--2,27)), - (2,22--2,27)), (2,20--2,28)), (2,4--2,16), - Yes (2,0--2,28), { LeadingKeyword = Let (2,0--2,3) - InlineKeyword = None - EqualsRange = Some (2,17--2,18) })], - (2,0--2,28))], PreXmlDocEmpty, [], None, (2,0--3,0), - { LeadingKeyword = None })], (true, true), - { ConditionalDirectives = [] - CodeComments = [] }, set [])) + Const (Int32 4, (2,26--2,27)), (2,24--2,27), + { SeparatorRange = Some (2,25--2,26) }), (2,22--2,27), + { SeparatorRange = Some (2,23--2,24) }), (2,20--2,28)), + (2,4--2,16), Yes (2,0--2,28), + { LeadingKeyword = Let (2,0--2,3) + InlineKeyword = None + EqualsRange = Some (2,17--2,18) })], (2,0--2,28))], + PreXmlDocEmpty, [], None, (2,0--3,0), { LeadingKeyword = None })], + (true, true), { ConditionalDirectives = [] + CodeComments = [] }, set []))