1 write to NestedRegions
Microsoft.CodeAnalysis (1)
Operations\ControlFlowRegion.cs (1)
81
NestedRegions
= nestedRegions.NullToEmpty();
74 references to NestedRegions
ILLink.RoslynAnalyzer (3)
DataFlow\ControlFlowGraphProxy.cs (3)
167
foreach (var nested in enclosingRegion.
NestedRegions
) {
190
foreach (var nested in tryRegion.Region.EnclosingRegion!.
NestedRegions
) {
198
foreach (var filter in nested.
NestedRegions
) {
Microsoft.CodeAnalysis (29)
Operations\ControlFlowBranch.cs (1)
149
builder.Add(leavingRegions[i + 1].
NestedRegions
.Last());
Operations\ControlFlowGraphBuilder.cs (13)
354
Debug.Assert(enclosing.
NestedRegions
[0] == region);
355
Debug.Assert(enclosing.
NestedRegions
[1].Kind == ControlFlowRegionKind.Finally);
356
if (!stepThroughSingleFinally(enclosing.
NestedRegions
[1]))
413
Debug.Assert(enclosing.
NestedRegions
[0] == fromRegion);
414
Debug.Assert(enclosing.
NestedRegions
[1].Kind == ControlFlowRegionKind.Finally);
415
if (!stepThroughSingleFinally(enclosing.
NestedRegions
[1]))
423
Debug.Assert(enclosing.
NestedRegions
[0] == fromRegion);
439
int index = tryAndCatch.
NestedRegions
.IndexOf(enclosing, startIndex: 1);
463
Debug.Assert(startAt <= tryAndCatch.
NestedRegions
.Length);
465
for (int i = startAt; i < tryAndCatch.
NestedRegions
.Length; i++)
467
ControlFlowRegion @catch = tryAndCatch.
NestedRegions
[i];
477
Debug.Assert(@catch.
NestedRegions
[0].Kind == ControlFlowRegionKind.Filter);
478
Debug.Assert(entryBlock.Ordinal == @catch.
NestedRegions
[0].FirstBlockOrdinal);
Operations\ControlFlowRegion.cs (15)
84
foreach (ControlFlowRegion r in
NestedRegions
)
96
Debug.Assert(
NestedRegions
.Length == 2);
97
Debug.Assert(
NestedRegions
[0].Kind == (kind == ControlFlowRegionKind.TryAndFinally ? ControlFlowRegionKind.Try : ControlFlowRegionKind.Filter));
98
Debug.Assert(
NestedRegions
[1].Kind == (kind == ControlFlowRegionKind.TryAndFinally ? ControlFlowRegionKind.Finally : ControlFlowRegionKind.Catch));
99
Debug.Assert(
NestedRegions
[0].FirstBlockOrdinal == firstBlockOrdinal);
100
Debug.Assert(
NestedRegions
[1].LastBlockOrdinal == lastBlockOrdinal);
101
Debug.Assert(
NestedRegions
[0].LastBlockOrdinal + 1 ==
NestedRegions
[1].FirstBlockOrdinal);
105
Debug.Assert(
NestedRegions
.Length >= 2);
106
Debug.Assert(
NestedRegions
[0].Kind == ControlFlowRegionKind.Try);
107
Debug.Assert(
NestedRegions
[0].FirstBlockOrdinal == firstBlockOrdinal);
108
previousLast =
NestedRegions
[0].LastBlockOrdinal;
110
for (int i = 1; i <
NestedRegions
.Length; i++)
112
ControlFlowRegion r =
NestedRegions
[i];
132
foreach (ControlFlowRegion r in
NestedRegions
)
Microsoft.CodeAnalysis.CodeStyle (13)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (13)
262
Debug.Assert(enclosing.
NestedRegions
[0] == region);
263
Debug.Assert(enclosing.
NestedRegions
[1].Kind == ControlFlowRegionKind.Finally);
264
if (!StepThroughSingleFinally(enclosing.
NestedRegions
[1], ref currentAnalysisData))
325
Debug.Assert(enclosing.
NestedRegions
[0] == fromRegion);
326
Debug.Assert(enclosing.
NestedRegions
[1].Kind == ControlFlowRegionKind.Finally);
328
if (!StepThroughSingleFinally(enclosing.
NestedRegions
[1], ref currentAnalysisData))
337
Debug.Assert(enclosing.
NestedRegions
[0] == fromRegion);
352
var index = tryAndCatch.
NestedRegions
.IndexOf(enclosing, startIndex: 1);
376
Debug.Assert(startAt <= tryAndCatch.
NestedRegions
.Length);
378
for (var i = startAt; i < tryAndCatch.
NestedRegions
.Length; i++)
380
var @catch = tryAndCatch.
NestedRegions
[i];
390
Debug.Assert(@catch.
NestedRegions
[0].Kind == ControlFlowRegionKind.Filter);
391
Debug.Assert(entryBlock.Ordinal == @catch.
NestedRegions
[0].FirstBlockOrdinal);
Microsoft.CodeAnalysis.Test.Utilities (16)
Compilation\ControlFlowGraphVerifier.cs (3)
738
Debug.Assert(region.EnclosingRegion.
NestedRegions
[1].Kind == ControlFlowRegionKind.Finally);
739
adjustAndGetEntryState(entryStates, blocks[region.EnclosingRegion.
NestedRegions
[1].FirstBlockOrdinal], state);
1357
foreach (ControlFlowRegion r in region.
NestedRegions
)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (13)
262
Debug.Assert(enclosing.
NestedRegions
[0] == region);
263
Debug.Assert(enclosing.
NestedRegions
[1].Kind == ControlFlowRegionKind.Finally);
264
if (!StepThroughSingleFinally(enclosing.
NestedRegions
[1], ref currentAnalysisData))
325
Debug.Assert(enclosing.
NestedRegions
[0] == fromRegion);
326
Debug.Assert(enclosing.
NestedRegions
[1].Kind == ControlFlowRegionKind.Finally);
328
if (!StepThroughSingleFinally(enclosing.
NestedRegions
[1], ref currentAnalysisData))
337
Debug.Assert(enclosing.
NestedRegions
[0] == fromRegion);
352
var index = tryAndCatch.
NestedRegions
.IndexOf(enclosing, startIndex: 1);
376
Debug.Assert(startAt <= tryAndCatch.
NestedRegions
.Length);
378
for (var i = startAt; i < tryAndCatch.
NestedRegions
.Length; i++)
380
var @catch = tryAndCatch.
NestedRegions
[i];
390
Debug.Assert(@catch.
NestedRegions
[0].Kind == ControlFlowRegionKind.Filter);
391
Debug.Assert(entryBlock.Ordinal == @catch.
NestedRegions
[0].FirstBlockOrdinal);
Microsoft.CodeAnalysis.Workspaces (13)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (13)
262
Debug.Assert(enclosing.
NestedRegions
[0] == region);
263
Debug.Assert(enclosing.
NestedRegions
[1].Kind == ControlFlowRegionKind.Finally);
264
if (!StepThroughSingleFinally(enclosing.
NestedRegions
[1], ref currentAnalysisData))
325
Debug.Assert(enclosing.
NestedRegions
[0] == fromRegion);
326
Debug.Assert(enclosing.
NestedRegions
[1].Kind == ControlFlowRegionKind.Finally);
328
if (!StepThroughSingleFinally(enclosing.
NestedRegions
[1], ref currentAnalysisData))
337
Debug.Assert(enclosing.
NestedRegions
[0] == fromRegion);
352
var index = tryAndCatch.
NestedRegions
.IndexOf(enclosing, startIndex: 1);
376
Debug.Assert(startAt <= tryAndCatch.
NestedRegions
.Length);
378
for (var i = startAt; i < tryAndCatch.
NestedRegions
.Length; i++)
380
var @catch = tryAndCatch.
NestedRegions
[i];
390
Debug.Assert(@catch.
NestedRegions
[0].Kind == ControlFlowRegionKind.Filter);
391
Debug.Assert(entryBlock.Ordinal == @catch.
NestedRegions
[0].FirstBlockOrdinal);