1 instantiation of ControlFlowRegion
Microsoft.CodeAnalysis (1)
Operations\ControlFlowGraphBuilder.RegionBuilder.cs (1)
337var result = new ControlFlowRegion(Kind, FirstBlock.Ordinal, LastBlock.Ordinal, subRegions,
275 references to ControlFlowRegion
GenerateDocumentationAndConfigFiles (18)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ControlFlowRegionExtensions.cs (1)
9internal static bool ContainsBlock(this ControlFlowRegion region, int destinationOrdinal)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\OperationExtensions.cs (1)
313var currentRegion = block.EnclosingRegion;
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (12)
33var continueDispatchAfterFinally = PooledDictionary<ControlFlowRegion, bool>.GetInstance(); 34var dispatchedExceptionsFromRegions = PooledHashSet<ControlFlowRegion>.GetInstance(); 74PooledDictionary<ControlFlowRegion, bool> continueDispatchAfterFinally, 75PooledHashSet<ControlFlowRegion> dispatchedExceptionsFromRegions, 254bool StepThroughFinally(ControlFlowRegion region, int destinationOrdinal, ref TBlockAnalysisData currentAnalysisData) 259var enclosing = region.EnclosingRegion; 278bool StepThroughSingleFinally(ControlFlowRegion @finally, ref TBlockAnalysisData currentAnalysisData) 310void DispatchException(ControlFlowRegion fromRegion) 319var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.EnclosingRegion; 349var tryAndCatch = enclosing.EnclosingRegion; 369void DispatchExceptionThroughCatches(ControlFlowRegion tryAndCatch, int startAt) 380var @catch = tryAndCatch.NestedRegions[i];
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
177foreach (var region in branch.LeavingRegions)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (3)
376var outermostEnclosingRegionStartingBlock = basicBlock.EnclosingRegion; 396ControlFlowRegion containingTryCatchFinallyRegion = null; 397var currentRegion = outermostEnclosingRegionStartingBlock;
ILLink.RoslynAnalyzer (10)
DataFlow\ControlFlowGraphProxy.cs (10)
36public readonly record struct RegionProxy(ControlFlowRegion Region) : IRegion<RegionProxy> 64foreach (var region in branch.FinallyRegions) 126private static bool TryGetTryOrCatchOrFilter(ControlFlowRegion? region, out RegionProxy tryOrCatchOrFilterRegion) 146ControlFlowRegion? region = block.Block.EnclosingRegion; 169var enclosingRegion = catchOrFilterOrFinallyRegion.Region.EnclosingRegion!; 178foreach (var nested in enclosingRegion.NestedRegions) 191var region = catchOrFilterRegion.Region; 202foreach (var nested in tryRegion.Region.EnclosingRegion!.NestedRegions) 204ControlFlowRegion? catchOrFilter = null; 212foreach (var filter in nested.NestedRegions)
Microsoft.CodeAnalysis (73)
Operations\BasicBlock.cs (2)
35ControlFlowRegion region) 132public ControlFlowRegion EnclosingRegion { get; }
Operations\ControlFlowBranch.cs (18)
18private ImmutableArray<ControlFlowRegion> _lazyLeavingRegions; 19private ImmutableArray<ControlFlowRegion> _lazyFinallyRegions; 20private ImmutableArray<ControlFlowRegion> _lazyEnteringRegions; 58public ImmutableArray<ControlFlowRegion> LeavingRegions 64ImmutableArray<ControlFlowRegion> result; 68result = ImmutableArray<ControlFlowRegion>.Empty; 82private static ArrayBuilder<ControlFlowRegion> CollectRegions(int destinationOrdinal, ControlFlowRegion source) 84var builder = ArrayBuilder<ControlFlowRegion>.GetInstance(); 101public ImmutableArray<ControlFlowRegion> EnteringRegions 107ImmutableArray<ControlFlowRegion> result; 111result = ImmutableArray<ControlFlowRegion>.Empty; 115ArrayBuilder<ControlFlowRegion> builder = CollectRegions(Source.Ordinal, Destination.EnclosingRegion); 131public ImmutableArray<ControlFlowRegion> FinallyRegions 137ArrayBuilder<ControlFlowRegion>? builder = null; 138ImmutableArray<ControlFlowRegion> leavingRegions = LeavingRegions; 146builder = ArrayBuilder<ControlFlowRegion>.GetInstance(); 154var result = builder == null ? ImmutableArray<ControlFlowRegion>.Empty : builder.ToImmutableAndFree();
Operations\ControlFlowGraph.cs (8)
27private readonly ImmutableDictionary<IMethodSymbol, (ControlFlowRegion region, ILocalFunctionOperation operation, int ordinal)> _localFunctionsMap; 29private readonly ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion region, int ordinal)> _anonymousFunctionsMap; 35ImmutableArray<BasicBlock> blocks, ControlFlowRegion root, 37ImmutableDictionary<IMethodSymbol, (ControlFlowRegion region, ILocalFunctionOperation operation, int ordinal)> localFunctionsMap, 38ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion region, int ordinal)> anonymousFunctionsMap) 217public ControlFlowRegion Root { get; } 246if (!_localFunctionsMap.TryGetValue(localFunction, out (ControlFlowRegion enclosing, ILocalFunctionOperation operation, int ordinal) info)) 295if (!_anonymousFunctionsMap.TryGetValue(anonymousFunction, out (ControlFlowRegion enclosing, int ordinal) info))
Operations\ControlFlowGraphBuilder.BasicBlockBuilder.cs (1)
33public ControlFlowRegion? Region;
Operations\ControlFlowGraphBuilder.cs (18)
87public static ControlFlowGraph Create(IOperation body, ControlFlowGraph? parent = null, ControlFlowRegion? enclosing = null, CaptureIdDispenser? captureIdDispenser = null, in Context context = default) 150var localFunctionsMap = ImmutableDictionary.CreateBuilder<IMethodSymbol, (ControlFlowRegion, ILocalFunctionOperation, int)>(); 151ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion, int)>.Builder? anonymousFunctionsMapOpt = null; 155anonymousFunctionsMapOpt = ImmutableDictionary.CreateBuilder<IFlowAnonymousFunctionOperation, (ControlFlowRegion, int)>(); 158ControlFlowRegion region = root.ToImmutableRegionAndFree(blocks, localFunctions, localFunctionsMap, anonymousFunctionsMapOpt, enclosing); 169anonymousFunctionsMapOpt?.ToImmutable() ?? ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion, int)>.Empty); 236var continueDispatchAfterFinally = PooledDictionary<ControlFlowRegion, bool>.GetInstance(); 237var dispatchedExceptionsFromRegions = PooledHashSet<ControlFlowRegion>.GetInstance(); 252PooledDictionary<ControlFlowRegion, bool> continueDispatchAfterFinally, 253PooledHashSet<ControlFlowRegion> dispatchedExceptionsFromRegions, 352bool stepThroughFinally(ControlFlowRegion region, BasicBlockBuilder destination) 359ControlFlowRegion enclosing = region.EnclosingRegion; 378bool stepThroughSingleFinally(ControlFlowRegion @finally) 406void dispatchException([DisallowNull] ControlFlowRegion? fromRegion) 415ControlFlowRegion? enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.EnclosingRegion; 444ControlFlowRegion tryAndCatch = enclosing.EnclosingRegion; 464void dispatchExceptionThroughCatches(ControlFlowRegion tryAndCatch, int startAt) 475ControlFlowRegion @catch = tryAndCatch.NestedRegions[i];
Operations\ControlFlowGraphBuilder.RegionBuilder.cs (19)
296public ControlFlowRegion ToImmutableRegionAndFree(ArrayBuilder<BasicBlockBuilder> blocks, 298ImmutableDictionary<IMethodSymbol, (ControlFlowRegion region, ILocalFunctionOperation operation, int ordinal)>.Builder localFunctionsMap, 299ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion region, int ordinal)>.Builder? anonymousFunctionsMapOpt, 300ControlFlowRegion? enclosing) 317ImmutableArray<ControlFlowRegion> subRegions; 321var builder = ArrayBuilder<ControlFlowRegion>.GetInstance(Regions.Count); 332subRegions = ImmutableArray<ControlFlowRegion>.Empty; 337var result = new ControlFlowRegion(Kind, FirstBlock.Ordinal, LastBlock.Ordinal, subRegions, 354foreach (ControlFlowRegion region in subRegions) 383(ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion region, int ordinal)>.Builder map, ControlFlowRegion region) argument = (anonymousFunctionsMapOpt, result); 399OperationVisitor<(ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion region, int ordinal)>.Builder map, ControlFlowRegion region), IOperation> 405(ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion region, int ordinal)>.Builder map, ControlFlowRegion region) argument) 411internal override IOperation? VisitNoneOperation(IOperation operation, (ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion region, int ordinal)>.Builder map, ControlFlowRegion region) argument) 418(ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion region, int ordinal)>.Builder map, ControlFlowRegion region) argument)
Operations\ControlFlowRegion.cs (7)
25public ControlFlowRegion? EnclosingRegion { get; private set; } 46public ImmutableArray<ControlFlowRegion> NestedRegions { get; } 64ImmutableArray<ControlFlowRegion> nestedRegions, 69ControlFlowRegion? enclosingRegion) 84foreach (ControlFlowRegion r in NestedRegions) 112ControlFlowRegion r = NestedRegions[i]; 132foreach (ControlFlowRegion r in NestedRegions)
Microsoft.CodeAnalysis.Analyzers (18)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ControlFlowRegionExtensions.cs (1)
9internal static bool ContainsBlock(this ControlFlowRegion region, int destinationOrdinal)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\OperationExtensions.cs (1)
313var currentRegion = block.EnclosingRegion;
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (12)
33var continueDispatchAfterFinally = PooledDictionary<ControlFlowRegion, bool>.GetInstance(); 34var dispatchedExceptionsFromRegions = PooledHashSet<ControlFlowRegion>.GetInstance(); 74PooledDictionary<ControlFlowRegion, bool> continueDispatchAfterFinally, 75PooledHashSet<ControlFlowRegion> dispatchedExceptionsFromRegions, 254bool StepThroughFinally(ControlFlowRegion region, int destinationOrdinal, ref TBlockAnalysisData currentAnalysisData) 259var enclosing = region.EnclosingRegion; 278bool StepThroughSingleFinally(ControlFlowRegion @finally, ref TBlockAnalysisData currentAnalysisData) 310void DispatchException(ControlFlowRegion fromRegion) 319var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.EnclosingRegion; 349var tryAndCatch = enclosing.EnclosingRegion; 369void DispatchExceptionThroughCatches(ControlFlowRegion tryAndCatch, int startAt) 380var @catch = tryAndCatch.NestedRegions[i];
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
177foreach (var region in branch.LeavingRegions)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (3)
376var outermostEnclosingRegionStartingBlock = basicBlock.EnclosingRegion; 396ControlFlowRegion containingTryCatchFinallyRegion = null; 397var currentRegion = outermostEnclosingRegionStartingBlock;
Microsoft.CodeAnalysis.AnalyzerUtilities (84)
src\roslyn\src\RoslynAnalyzers\Utilities\FlowAnalysis\BranchWithInfo.cs (20)
17private static readonly Func<ControlFlowRegion, IEnumerable<ControlFlowRegion>> s_getTransitiveNestedRegions = GetTransitiveNestedRegions; 30enteringRegions: ImmutableArray<ControlFlowRegion>.Empty, 31leavingRegions: ImmutableArray<ControlFlowRegion>.Empty, 32finallyRegions: ImmutableArray<ControlFlowRegion>.Empty, 43ImmutableArray<ControlFlowRegion> enteringRegions, 44ImmutableArray<ControlFlowRegion> leavingRegions, 45ImmutableArray<ControlFlowRegion> finallyRegions, 65public ImmutableArray<ControlFlowRegion> EnteringRegions { get; } 66public ImmutableArray<ControlFlowRegion> FinallyRegions { get; } 67public ImmutableArray<ControlFlowRegion> LeavingRegions { get; } 79enteringRegions: ImmutableArray<ControlFlowRegion>.Empty, 80leavingRegions: ImmutableArray<ControlFlowRegion>.Empty, 81finallyRegions: ImmutableArray<ControlFlowRegion>.Empty, 98private static IEnumerable<ControlFlowRegion> GetTransitiveNestedRegions(ControlFlowRegion region) 102foreach (var nestedRegion in region.NestedRegions) 104foreach (var transitiveNestedRegion in GetTransitiveNestedRegions(nestedRegion)) 111private static IEnumerable<ILocalSymbol> ComputeLeavingRegionLocals(ImmutableArray<ControlFlowRegion> leavingRegions) 116private static IEnumerable<CaptureId> ComputeLeavingRegionFlowCaptures(ImmutableArray<ControlFlowRegion> leavingRegions)
src\roslyn\src\RoslynAnalyzers\Utilities\FlowAnalysis\Extensions\BasicBlockExtensions.cs (13)
23var lastFinally = predecessorBranch.FinallyRegions[^1]; 35var region = basicBlock.EnclosingRegion; 58public static ControlFlowRegion? GetContainingRegionOfKind(this BasicBlock basicBlock, ControlFlowRegionKind regionKind) 60var enclosingRegion = basicBlock.EnclosingRegion; 77public static bool IsFirstBlockOfFinally(this BasicBlock basicBlock, [NotNullWhen(returnValue: true)] out ControlFlowRegion? finallyRegion) 83public static bool IsLastBlockOfFinally(this BasicBlock basicBlock, [NotNullWhen(returnValue: true)] out ControlFlowRegion? finallyRegion) 89public static bool IsFirstBlockOfRegionKind(this BasicBlock basicBlock, ControlFlowRegionKind regionKind, [NotNullWhen(returnValue: true)] out ControlFlowRegion? region) 95public static bool IsLastBlockOfRegionKind(this BasicBlock basicBlock, ControlFlowRegionKind regionKind, [NotNullWhen(returnValue: true)] out ControlFlowRegion? region) 98private static bool IsFirstOrLastBlockOfRegionKind(this BasicBlock basicBlock, ControlFlowRegionKind regionKind, bool first, [NotNullWhen(returnValue: true)] out ControlFlowRegion? foundRegion) 102var enclosingRegion = basicBlock.EnclosingRegion; 128if (!basicBlock.IsFirstBlockOfRegionKind(ControlFlowRegionKind.Finally, out var finallyRegion)) 144internal static ControlFlowRegion? GetInnermostRegionStartedByBlock(this BasicBlock basicBlock, ControlFlowRegionKind regionKind) 151var enclosingRegion = basicBlock.EnclosingRegion;
src\roslyn\src\RoslynAnalyzers\Utilities\FlowAnalysis\Extensions\ControlFlowRegionExtensions.cs (3)
11public static bool ContainsRegionOrSelf(this ControlFlowRegion controlFlowRegion, ControlFlowRegion nestedRegion) 15public static IEnumerable<IOperation> DescendantOperations(this ControlFlowRegion controlFlowRegion, ControlFlowGraph cfg)
src\roslyn\src\RoslynAnalyzers\Utilities\FlowAnalysis\Extensions\IOperationExtensions_FlowAnalysis.cs (1)
24var currentRegion = block.EnclosingRegion;
src\roslyn\src\RoslynAnalyzers\Utilities\FlowAnalysis\FlowAnalysis\Framework\DataFlow\DataFlowAnalysis.cs (21)
66var catchBlockInputDataMap = PooledDictionary<ControlFlowRegion, TAnalysisData>.GetInstance(); 190PooledDictionary<ControlFlowRegion, TAnalysisData> catchBlockInputDataMap, 228var finallyRegion = block.GetInnermostRegionStartedByBlock(ControlFlowRegionKind.Finally); 232var tryRegion = finallyRegion.EnclosingRegion.NestedRegions[0]; 274ControlFlowRegion? enclosingTryAndCatchRegion = GetEnclosingTryAndCatchRegionIfStartsHandler(block); 349if (successorBlock.IsFirstBlockOfRegionKind(ControlFlowRegionKind.TryAndFinally, out var tryAndFinally)) 351var finallyRegion = tryAndFinally.NestedRegions[1]; 490static ControlFlowRegion? TryGetReachableCatchRegionStartingHandler(ControlFlowRegion tryAndCatchRegion, BasicBlock sourceBlock) 497var catchRegion = tryAndCatchRegion.NestedRegions.FirstOrDefault(region => region.Kind is ControlFlowRegionKind.Catch or ControlFlowRegionKind.FilterAndHandler); 506ControlFlowRegion? MergeIntoCatchInputData(ControlFlowRegion tryAndCatchRegion, TAnalysisData dataToMerge, BasicBlock sourceBlock) 508var catchRegion = TryGetReachableCatchRegionStartingHandler(tryAndCatchRegion, sourceBlock); 592static ControlFlowRegion? GetEnclosingTryAndCatchRegionIfStartsHandler(BasicBlock block) 654var firstFinally = branch.FinallyRegions[0]; 674ControlFlowRegion finallyRegion = branch.FinallyRegions[i]; 683foreach (var region in branch.LeavingRegions) 694var catchRegion = TryGetReachableCatchRegionStartingHandler(region, sourceBlock); 699ControlFlowRegion finallyRegion = branch.FinallyRegions[i]; 715var catchRegion = MergeIntoCatchInputData(region, branchData, sourceBlock); 727void AddFinallySuccessor(ControlFlowRegion finallyRegion, BranchWithInfo successor)
src\roslyn\src\RoslynAnalyzers\Utilities\FlowAnalysis\FlowAnalysis\Framework\DataFlow\DataFlowOperationVisitor.cs (3)
484if (AnalysisDataForUnhandledThrowOperations != null && block.IsLastBlockOfFinally(out var finallyRegion)) 3795var tryFinallyRegion = CurrentBasicBlock.GetContainingRegionOfKind(ControlFlowRegionKind.TryAndFinally)!; 3796var tryRegion = tryFinallyRegion.NestedRegions[0];
src\roslyn\src\RoslynAnalyzers\Utilities\FlowAnalysis\FlowAnalysis\Framework\DataFlow\ThrownExceptionInfo.cs (5)
43private static ControlFlowRegion? GetHandlerRegion(BasicBlock block, INamedTypeSymbol exceptionType) 45var enclosingRegion = block.EnclosingRegion; 51foreach (var nestedRegion in enclosingRegion.NestedRegions.Skip(1)) 83internal ControlFlowRegion? HandlingCatchRegion { get; } 88internal ControlFlowRegion? ContainingFinallyRegion { get; }
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ControlFlowRegionExtensions.cs (1)
9internal static bool ContainsBlock(this ControlFlowRegion region, int destinationOrdinal)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\OperationExtensions.cs (1)
313var currentRegion = block.EnclosingRegion;
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (12)
33var continueDispatchAfterFinally = PooledDictionary<ControlFlowRegion, bool>.GetInstance(); 34var dispatchedExceptionsFromRegions = PooledHashSet<ControlFlowRegion>.GetInstance(); 74PooledDictionary<ControlFlowRegion, bool> continueDispatchAfterFinally, 75PooledHashSet<ControlFlowRegion> dispatchedExceptionsFromRegions, 254bool StepThroughFinally(ControlFlowRegion region, int destinationOrdinal, ref TBlockAnalysisData currentAnalysisData) 259var enclosing = region.EnclosingRegion; 278bool StepThroughSingleFinally(ControlFlowRegion @finally, ref TBlockAnalysisData currentAnalysisData) 310void DispatchException(ControlFlowRegion fromRegion) 319var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.EnclosingRegion; 349var tryAndCatch = enclosing.EnclosingRegion; 369void DispatchExceptionThroughCatches(ControlFlowRegion tryAndCatch, int startAt) 380var @catch = tryAndCatch.NestedRegions[i];
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
177foreach (var region in branch.LeavingRegions)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (3)
376var outermostEnclosingRegionStartingBlock = basicBlock.EnclosingRegion; 396ControlFlowRegion containingTryCatchFinallyRegion = null; 397var currentRegion = outermostEnclosingRegionStartingBlock;
Microsoft.CodeAnalysis.CodeStyle (18)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ControlFlowRegionExtensions.cs (1)
9internal static bool ContainsBlock(this ControlFlowRegion region, int destinationOrdinal)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\OperationExtensions.cs (1)
313var currentRegion = block.EnclosingRegion;
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (12)
33var continueDispatchAfterFinally = PooledDictionary<ControlFlowRegion, bool>.GetInstance(); 34var dispatchedExceptionsFromRegions = PooledHashSet<ControlFlowRegion>.GetInstance(); 74PooledDictionary<ControlFlowRegion, bool> continueDispatchAfterFinally, 75PooledHashSet<ControlFlowRegion> dispatchedExceptionsFromRegions, 254bool StepThroughFinally(ControlFlowRegion region, int destinationOrdinal, ref TBlockAnalysisData currentAnalysisData) 259var enclosing = region.EnclosingRegion; 278bool StepThroughSingleFinally(ControlFlowRegion @finally, ref TBlockAnalysisData currentAnalysisData) 310void DispatchException(ControlFlowRegion fromRegion) 319var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.EnclosingRegion; 349var tryAndCatch = enclosing.EnclosingRegion; 369void DispatchExceptionThroughCatches(ControlFlowRegion tryAndCatch, int startAt) 380var @catch = tryAndCatch.NestedRegions[i];
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
177foreach (var region in branch.LeavingRegions)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (3)
376var outermostEnclosingRegionStartingBlock = basicBlock.EnclosingRegion; 396ControlFlowRegion containingTryCatchFinallyRegion = null; 397var currentRegion = outermostEnclosingRegionStartingBlock;
Microsoft.CodeAnalysis.ResxSourceGenerator (18)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ControlFlowRegionExtensions.cs (1)
9internal static bool ContainsBlock(this ControlFlowRegion region, int destinationOrdinal)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\OperationExtensions.cs (1)
313var currentRegion = block.EnclosingRegion;
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (12)
33var continueDispatchAfterFinally = PooledDictionary<ControlFlowRegion, bool>.GetInstance(); 34var dispatchedExceptionsFromRegions = PooledHashSet<ControlFlowRegion>.GetInstance(); 74PooledDictionary<ControlFlowRegion, bool> continueDispatchAfterFinally, 75PooledHashSet<ControlFlowRegion> dispatchedExceptionsFromRegions, 254bool StepThroughFinally(ControlFlowRegion region, int destinationOrdinal, ref TBlockAnalysisData currentAnalysisData) 259var enclosing = region.EnclosingRegion; 278bool StepThroughSingleFinally(ControlFlowRegion @finally, ref TBlockAnalysisData currentAnalysisData) 310void DispatchException(ControlFlowRegion fromRegion) 319var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.EnclosingRegion; 349var tryAndCatch = enclosing.EnclosingRegion; 369void DispatchExceptionThroughCatches(ControlFlowRegion tryAndCatch, int startAt) 380var @catch = tryAndCatch.NestedRegions[i];
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
177foreach (var region in branch.LeavingRegions)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (3)
376var outermostEnclosingRegionStartingBlock = basicBlock.EnclosingRegion; 396ControlFlowRegion containingTryCatchFinallyRegion = null; 397var currentRegion = outermostEnclosingRegionStartingBlock;
Microsoft.CodeAnalysis.Workspaces (18)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ControlFlowRegionExtensions.cs (1)
9internal static bool ContainsBlock(this ControlFlowRegion region, int destinationOrdinal)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\OperationExtensions.cs (1)
313var currentRegion = block.EnclosingRegion;
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (12)
33var continueDispatchAfterFinally = PooledDictionary<ControlFlowRegion, bool>.GetInstance(); 34var dispatchedExceptionsFromRegions = PooledHashSet<ControlFlowRegion>.GetInstance(); 74PooledDictionary<ControlFlowRegion, bool> continueDispatchAfterFinally, 75PooledHashSet<ControlFlowRegion> dispatchedExceptionsFromRegions, 254bool StepThroughFinally(ControlFlowRegion region, int destinationOrdinal, ref TBlockAnalysisData currentAnalysisData) 259var enclosing = region.EnclosingRegion; 278bool StepThroughSingleFinally(ControlFlowRegion @finally, ref TBlockAnalysisData currentAnalysisData) 310void DispatchException(ControlFlowRegion fromRegion) 319var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.EnclosingRegion; 349var tryAndCatch = enclosing.EnclosingRegion; 369void DispatchExceptionThroughCatches(ControlFlowRegion tryAndCatch, int startAt) 380var @catch = tryAndCatch.NestedRegions[i];
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
177foreach (var region in branch.LeavingRegions)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (3)
376var outermostEnclosingRegionStartingBlock = basicBlock.EnclosingRegion; 396ControlFlowRegion containingTryCatchFinallyRegion = null; 397var currentRegion = outermostEnclosingRegionStartingBlock;
Roslyn.Diagnostics.Analyzers (18)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ControlFlowRegionExtensions.cs (1)
9internal static bool ContainsBlock(this ControlFlowRegion region, int destinationOrdinal)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\OperationExtensions.cs (1)
313var currentRegion = block.EnclosingRegion;
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (12)
33var continueDispatchAfterFinally = PooledDictionary<ControlFlowRegion, bool>.GetInstance(); 34var dispatchedExceptionsFromRegions = PooledHashSet<ControlFlowRegion>.GetInstance(); 74PooledDictionary<ControlFlowRegion, bool> continueDispatchAfterFinally, 75PooledHashSet<ControlFlowRegion> dispatchedExceptionsFromRegions, 254bool StepThroughFinally(ControlFlowRegion region, int destinationOrdinal, ref TBlockAnalysisData currentAnalysisData) 259var enclosing = region.EnclosingRegion; 278bool StepThroughSingleFinally(ControlFlowRegion @finally, ref TBlockAnalysisData currentAnalysisData) 310void DispatchException(ControlFlowRegion fromRegion) 319var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.EnclosingRegion; 349var tryAndCatch = enclosing.EnclosingRegion; 369void DispatchExceptionThroughCatches(ControlFlowRegion tryAndCatch, int startAt) 380var @catch = tryAndCatch.NestedRegions[i];
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
177foreach (var region in branch.LeavingRegions)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (3)
376var outermostEnclosingRegionStartingBlock = basicBlock.EnclosingRegion; 396ControlFlowRegion containingTryCatchFinallyRegion = null; 397var currentRegion = outermostEnclosingRegionStartingBlock;