@@ -2560,13 +2560,6 @@ and GenLinearExpr cenv cgbuf eenv sp expr sequel canProcessSequencePoint (contf:
25602560 ProcessSequencePointForExpr cenv cgbuf sp expr
25612561
25622562 match expr with
2563- | LinearOpExpr ( TOp.UnionCase c, tyargs, argsFront, argLast, m) ->
2564- GenExprs cenv cgbuf eenv argsFront
2565- GenLinearExpr cenv cgbuf eenv SPSuppress argLast Continue (* canProcessSequencePoint *) true ( contf << ( fun Fake ->
2566- GenAllocUnionCaseCore cenv cgbuf eenv ( c, tyargs, argsFront.Length + 1 , m)
2567- GenSequel cenv eenv.cloc cgbuf sequel
2568- Fake))
2569-
25702563 | Expr.Sequential ( e1, e2, specialSeqFlag, spSeq, _) ->
25712564 // Compiler generated sequential executions result in suppressions of sequence points on both
25722565 // left and right of the sequence
@@ -2610,8 +2603,14 @@ and GenLinearExpr cenv cgbuf eenv sp expr sequel canProcessSequencePoint (contf:
26102603 | LinearMatchExpr ( spBind, exprm, tree, tg1, e2, spTg2, m, ty) ->
26112604 GenMatch cenv cgbuf eenv ( spBind, exprm, tree, [| tg1; TTarget([], e2, spTg2)|], m, ty) sequel
26122605 contf Fake
2613- //| Expr.Match (spBind, exprm, tree, targets, m, ty) ->
2614- // GenMatch cenv cgbuf eenv (spBind, exprm, tree, targets, m, ty) sequel
2606+
2607+ | LinearOpExpr ( TOp.UnionCase c, tyargs, argsFront, argLast, m) ->
2608+ GenExprs cenv cgbuf eenv argsFront
2609+ GenLinearExpr cenv cgbuf eenv SPSuppress argLast Continue (* canProcessSequencePoint *) true ( contf << ( fun Fake ->
2610+ GenAllocUnionCaseCore cenv cgbuf eenv ( c, tyargs, argsFront.Length + 1 , m)
2611+ GenSequel cenv eenv.cloc cgbuf sequel
2612+ Fake))
2613+
26152614 | _ ->
26162615 GenExpr cenv cgbuf eenv sp expr sequel
26172616 contf Fake
@@ -4376,7 +4375,10 @@ and GenLambdaClosure cenv (cgbuf: CodeGenBuffer) eenv isLocalTypeFunc selfv expr
43764375 | Some v -> [( v, BranchCallClosure ( cloinfo.cloArityInfo))]
43774376 | _ -> []
43784377
4379- DelayGenMethodForLambda cenv cgbuf.mgbuf eenv ( entryPointInfo, cloinfo, eenvinner, body, isLocalTypeFunc, m)
4378+ if cenv.exprRecursionDepth > 0 then
4379+ DelayGenMethodForLambda cenv cgbuf.mgbuf eenv ( entryPointInfo, cloinfo, eenvinner, body, isLocalTypeFunc, m)
4380+ else
4381+ GenMethodForLambda cenv cgbuf.mgbuf eenv ( entryPointInfo, cloinfo, eenvinner, body, isLocalTypeFunc, m)
43804382 cloinfo, m
43814383
43824384 | _ -> failwith " GenLambda: not a lambda"
0 commit comments