2 writes to EnclosingRegion
Microsoft.CodeAnalysis (2)
Operations\ControlFlowRegion.cs (2)
82
EnclosingRegion
= enclosingRegion;
87
r.
EnclosingRegion
= this;
60 references to EnclosingRegion
ILLink.RoslynAnalyzer (8)
DataFlow\ControlFlowGraphProxy.cs (8)
117
return TryGetTryOrCatchOrFilter (regionProxy.Region.
EnclosingRegion
, out tryOrCatchOrFilterRegion);
130
region = region.
EnclosingRegion
;
146
region = region.
EnclosingRegion
;
159
var enclosingRegion = catchOrFilterOrFinallyRegion.Region.
EnclosingRegion
!;
162
enclosingRegion = enclosingRegion.
EnclosingRegion
!;
184
if (region.Kind is ControlFlowRegionKind.Catch && region.
EnclosingRegion
!.Kind is ControlFlowRegionKind.FilterAndHandler)
190
foreach (var nested in tryRegion.Region.
EnclosingRegion
!.NestedRegions) {
228
return catchRegion.Region.
EnclosingRegion
!.Kind == ControlFlowRegionKind.FilterAndHandler;
Microsoft.CodeAnalysis (8)
Operations\ControlFlowBranch.cs (2)
89
Debug.Assert(source.
EnclosingRegion
!= null);
91
source = source.
EnclosingRegion
;
Operations\ControlFlowGraphBuilder.cs (5)
350
Debug.Assert(region.
EnclosingRegion
!= null);
351
ControlFlowRegion enclosing = region.
EnclosingRegion
;
407
ControlFlowRegion? enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.
EnclosingRegion
;
435
Debug.Assert(enclosing.
EnclosingRegion
!= null);
436
ControlFlowRegion tryAndCatch = enclosing.
EnclosingRegion
;
Operations\ControlFlowRegion.cs (1)
86
Debug.Assert(r.
EnclosingRegion
== null && r.Kind != ControlFlowRegionKind.Root);
Microsoft.CodeAnalysis.CodeStyle (7)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\OperationExtensions.cs (1)
320
currentRegion = currentRegion.
EnclosingRegion
;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (3)
259
var enclosing = region.
EnclosingRegion
;
319
var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.
EnclosingRegion
;
349
var tryAndCatch = enclosing.
EnclosingRegion
;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (3)
362
while (outermostEnclosingRegionStartingBlock.
EnclosingRegion
?.FirstBlockOrdinal == basicBlock.Ordinal)
364
outermostEnclosingRegionStartingBlock = outermostEnclosingRegionStartingBlock.
EnclosingRegion
;
393
currentRegion = currentRegion.
EnclosingRegion
;
Microsoft.CodeAnalysis.Test.Utilities (30)
Compilation\ControlFlowGraphVerifier.cs (27)
146
Assert.Same(enclosing, currentRegion.
EnclosingRegion
);
467
region = region.
EnclosingRegion
;
736
if (region.Kind == ControlFlowRegionKind.Try && region.
EnclosingRegion
.Kind == ControlFlowRegionKind.TryAndFinally)
738
Debug.Assert(region.
EnclosingRegion
.NestedRegions[1].Kind == ControlFlowRegionKind.Finally);
739
adjustAndGetEntryState(entryStates, blocks[region.
EnclosingRegion
.NestedRegions[1].FirstBlockOrdinal], state);
742
region = region.
EnclosingRegion
;
801
if (block.EnclosingRegion.
EnclosingRegion
.CaptureIds.Contains(id))
813
else if (block.EnclosingRegion.
EnclosingRegion
?.
EnclosingRegion
.CaptureIds.Contains(id) ?? false)
1023
ControlFlowRegion region = graph.Root.
EnclosingRegion
;
1032
region = region.
EnclosingRegion
;
1427
enterRegions(region.
EnclosingRegion
, firstBlockOrdinal);
1436
Assert.Equal(firstBlockOrdinal, region.
EnclosingRegion
.FirstBlockOrdinal);
1437
Assert.Same(region.ExceptionType, region.
EnclosingRegion
.ExceptionType);
1442
Assert.Equal(firstBlockOrdinal, region.
EnclosingRegion
.FirstBlockOrdinal);
1443
enterRegion($".try {{{getRegionId(region.
EnclosingRegion
)}, {getRegionId(region)}}}");
1453
switch (region.
EnclosingRegion
.Kind)
1456
Assert.Same(region.ExceptionType, region.
EnclosingRegion
.ExceptionType);
1463
Assert.False(true, $"Unexpected region kind {region.
EnclosingRegion
.Kind}");
1542
switch (region.
EnclosingRegion
.Kind)
1549
Assert.False(true, $"Unexpected region kind {region.
EnclosingRegion
.Kind}");
1566
leaveRegions(region.
EnclosingRegion
, lastBlockOrdinal);
1597
remainedIn1 = r.
EnclosingRegion
;
1609
remainedIn2 = r.
EnclosingRegion
;
1613
Assert.Same(remainedIn1.
EnclosingRegion
, remainedIn2.
EnclosingRegion
);
1680
region = region.
EnclosingRegion
;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (3)
259
var enclosing = region.
EnclosingRegion
;
319
var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.
EnclosingRegion
;
349
var tryAndCatch = enclosing.
EnclosingRegion
;
Microsoft.CodeAnalysis.Workspaces (7)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\OperationExtensions.cs (1)
320
currentRegion = currentRegion.
EnclosingRegion
;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\CustomDataFlowAnalysis.cs (3)
259
var enclosing = region.
EnclosingRegion
;
319
var enclosing = fromRegion.Kind == ControlFlowRegionKind.Root ? null : fromRegion.
EnclosingRegion
;
349
var tryAndCatch = enclosing.
EnclosingRegion
;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (3)
362
while (outermostEnclosingRegionStartingBlock.
EnclosingRegion
?.FirstBlockOrdinal == basicBlock.Ordinal)
364
outermostEnclosingRegionStartingBlock = outermostEnclosingRegionStartingBlock.
EnclosingRegion
;
393
currentRegion = currentRegion.
EnclosingRegion
;