13 references to FlowCaptureKind
Microsoft.CodeAnalysis.CodeStyle (13)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\LValueFlowCaptureProvider.cs (8)
40
public static ImmutableDictionary<CaptureId,
FlowCaptureKind
> CreateLValueFlowCaptures(ControlFlowGraph cfg)
49
ImmutableDictionary<CaptureId,
FlowCaptureKind
>.Builder lvalueFlowCaptureIdBuilder = null;
60
lvalueFlowCaptureIdBuilder ??= ImmutableDictionary.CreateBuilder<CaptureId,
FlowCaptureKind
>();
61
var
captureKind = flowCaptureReference.Parent.IsAnyCompoundAssignment() || rvalueFlowCaptureIds.Contains(flowCaptureReference.Id)
62
?
FlowCaptureKind
.LValueAndRValueCapture
63
:
FlowCaptureKind
.LValueCapture;
76
Debug.Assert(kind ==
FlowCaptureKind
.LValueAndRValueCapture || !rvalueFlowCaptureIds.Contains(captureId), "Flow capture used as both an r-value and an l-value, but with incorrect flow capture kind");
80
return lvalueFlowCaptureIdBuilder != null ? lvalueFlowCaptureIdBuilder.ToImmutable() : ImmutableDictionary<CaptureId,
FlowCaptureKind
>.Empty;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (5)
101
Debug.Assert(LValueFlowCapturesInGraph.Values.All(kind => kind is
FlowCaptureKind
.LValueCapture or
FlowCaptureKind
.LValueAndRValueCapture));
181
public ImmutableDictionary<CaptureId,
FlowCaptureKind
> LValueFlowCapturesInGraph { get; }
461
=> !LValueFlowCapturesInGraph.TryGetValue(captureId, out
var
captureKind) || captureKind !=
FlowCaptureKind
.LValueCapture;