1 write to _F
Microsoft.CodeAnalysis.CSharp (1)
Lowering\AsyncRewriter\AsyncExceptionHandlerRewriter.cs (1)
39_F = factory;
140 references to _F
Microsoft.CodeAnalysis.CSharp (140)
Lowering\AsyncRewriter\AsyncExceptionHandlerRewriter.cs (140)
40_F.CurrentFunction = containingMethod; 163result = _F.Block( 165_F.Throw(_F.Null(_F.SpecialType(SpecialType.System_Object))) 179var oldTrySyntax = _F.Syntax; 180_F.Syntax = tryStatementSyntax; 184_F.Syntax = oldTrySyntax; 213return _F.Try((BoundBlock)finalizedRegion, ImmutableArray<BoundCatchBlock>.Empty, rewrittenFinally); 223var exceptionType = _F.SpecialType(SpecialType.System_Object); 224var pendingExceptionLocal = new SynthesizedLocal(_F.CurrentFunction, TypeWithAnnotations.Create(exceptionType), SynthesizedLocalKind.TryAwaitPendingException, tryStatementSyntax); 225var finallyLabel = _F.GenerateLabel("finallyLabel"); 226var pendingBranchVar = new SynthesizedLocal(_F.CurrentFunction, TypeWithAnnotations.Create(_F.SpecialType(SpecialType.System_Int32)), SynthesizedLocalKind.TryAwaitPendingBranch, tryStatementSyntax); 228var catchAll = _F.Catch(_F.Local(pendingExceptionLocal), _F.Block()); 230var catchAndPendException = _F.Try( 231_F.Block( 233_F.HiddenSequencePoint(), 234_F.Goto(finallyLabel), 239BoundBlock syntheticFinallyBlock = _F.Block( 240_F.HiddenSequencePoint(), 241_F.Label(finallyLabel), 243_F.HiddenSequencePoint(), 250if (_F.CurrentFunction.IsAsync && _F.CurrentFunction.IsIterator) 253syntheticFinally = _F.ExtractedFinallyBlock(syntheticFinallyBlock); 259statements.Add(_F.HiddenSequencePoint()); 262statements.Add(_F.Assignment(_F.Local(pendingExceptionLocal), _F.Default(pendingExceptionLocal.Type))); 264statements.Add(_F.Assignment(_F.Local(pendingBranchVar), _F.Default(pendingBranchVar.Type))); 275var completeTry = _F.Block( 313return _F.Block(bodyStatements.ToImmutableAndFree()); 324bodyStatements.Add(_F.Label(proxy)); 327bodyStatements.Add(_F.Assignment(_F.Local(pendingBranchVar), _F.Literal(i))); 330bodyStatements.Add(_F.Goto(finallyLabel)); 352var caseStatement = _F.SwitchSection(i, _F.Goto(parentProxy)); 362pendingValue = _F.Local(frame.returnValue); 368var returnLabel = parent.ProxyReturnIfNeeded(_F.CurrentFunction, pendingValue, out returnValue); 372unpendReturn = new BoundReturnStatement(_F.Syntax, RefKind.None, pendingValue, @checked: false); 378unpendReturn = _F.Goto(returnLabel); 382unpendReturn = _F.Block( 383_F.Assignment( 384_F.Local(returnValue), 386_F.Goto(returnLabel)); 390var caseStatement = _F.SwitchSection(i, unpendReturn); 395return _F.Switch(_F.Local(pendingBranchVar), cases.ToImmutableAndFree()); 416_F.CurrentFunction, 428return _F.Block( 429_F.Assignment( 430_F.Local(returnValue), 432_F.Goto( 437return _F.Goto(returnLabel); 445if (_F.Compilation.IsRuntimeAsyncEnabledIn(_F.CurrentFunction)) 454LocalSymbol obj = _F.SynthesizedLocal(_F.SpecialType(SpecialType.System_Object)); 455var objInit = _F.Assignment(_F.Local(obj), _F.Local(pendingExceptionLocal)); 458return _F.Block( 467BoundStatement checkAndThrow = _F.If( 468_F.ObjectNotEqual( 469_F.Local(obj), 470_F.Null(obj.Type)), 479BoundStatement rethrow = _F.Throw(_F.Local(obj)); 481var exceptionDispatchInfoCapture = _F.WellKnownMethod(WellKnownMember.System_Runtime_ExceptionServices_ExceptionDispatchInfo__Capture, isOptional: true); 482var exceptionDispatchInfoThrow = _F.WellKnownMethod(WellKnownMember.System_Runtime_ExceptionServices_ExceptionDispatchInfo__Throw, isOptional: true); 488var ex = _F.SynthesizedLocal(_F.WellKnownType(WellKnownType.System_Exception)); 489var assignment = _F.Assignment( 490_F.Local(ex), 491_F.As(_F.Local(obj), ex.Type)); 494rethrow = _F.Block( 497_F.If(_F.ObjectEqual(_F.Local(ex), _F.Null(ex.Type)), rethrow), 499_F.ExpressionStatement( 500_F.Call( 501_F.StaticCall( 504_F.Local(ex)), 534BoundStatement tryWithCatches = _F.Try(rewrittenTry, rewrittenCatches); 539var handledLabel = _F.GenerateLabel("handled"); 544handlers.Add(_F.SwitchSection( 546_F.Block( 548_F.Goto(handledLabel)))); 551tryWithCatches = _F.Block( 556_F.HiddenSequencePoint(), 557_F.Assignment( 558_F.Local(currentAwaitCatchFrame.pendingCatch), 559_F.Default(currentAwaitCatchFrame.pendingCatch.Type)), 561_F.HiddenSequencePoint(), 562_F.Switch( 563_F.Local(currentAwaitCatchFrame.pendingCatch), 565_F.HiddenSequencePoint(), 566_F.Label(handledLabel)); 611currentAwaitCatchFrame = _currentAwaitCatchFrame = new AwaitCatchFrame(_F, tryStatementSyntax, parentAwaitCatchFrame); 614var catchType = node.ExceptionTypeOpt ?? _F.SpecialType(SpecialType.System_Object); 615var catchTemp = _F.SynthesizedLocal(catchType); 617var storePending = _F.AssignmentExpression( 618_F.Local(currentAwaitCatchFrame.pendingCaughtException), 619_F.Convert(currentAwaitCatchFrame.pendingCaughtException.Type, 620_F.Local(catchTemp))); 622var setPendingCatchNum = _F.Assignment( 623_F.Local(currentAwaitCatchFrame.pendingCatch), 624_F.Literal(currentAwaitCatchFrame.handlers.Count + 1)); 643_F.Local(catchTemp), 647body: _F.Block( 648_F.HiddenSequencePoint(), 649_F.ExpressionStatement(storePending), 664currentAwaitCatchFrame.HoistLocal(local, _F); 673prologueBuilder.Add(_F.ExpressionStatement(storePending)); 676prologueBuilder.Add(_F.ExpressionStatement(AssignCatchSource((BoundExpression)this.Visit(sourceOpt), currentAwaitCatchFrame))); 683var newPrologue = _F.StatementList(prologueBuilder.ToImmutableAndFree()); 689_F.Local(catchTemp), 693body: _F.Block( 694_F.HiddenSequencePoint(), 701handlerStatements.Add(_F.HiddenSequencePoint()); 709handlerStatements.Add(_F.ExpressionStatement(assignSource)); 715var handler = _F.Block( 731assignSource = _F.AssignmentExpression( 733_F.Convert( 735_F.Local(currentAwaitCatchFrame.pendingCaughtException))); 767var oldContainingSymbol = _F.CurrentFunction; 771_F.CurrentFunction = node.Symbol; 784_F.CurrentFunction = oldContainingSymbol; 793var oldContainingSymbol = _F.CurrentFunction; 797_F.CurrentFunction = node.Symbol; 804_F.CurrentFunction = oldContainingSymbol;