3 instantiations of CaptureId
Microsoft.CodeAnalysis (3)
Operations\ControlFlowGraphBuilder.RegionBuilder.cs (1)
73CaptureIds.Add(new CaptureId(captureId));
Operations\OperationNodes.cs (2)
642this(new CaptureId(id), isInitialization, semanticModel: null, syntax: syntax, type: type, constantValue: constantValue, isImplicit: true) 650this(new CaptureId(id), value, semanticModel: null, syntax: syntax, isImplicit: true)
120 references to CaptureId
ILLink.RoslynAnalyzer (22)
DataFlow\LocalDataFlowAnalysis.cs (1)
119 ImmutableDictionary<CaptureId, FlowCaptureKind> lValueFlowCaptures,
DataFlow\LocalDataFlowVisitor.cs (4)
49 private readonly ImmutableDictionary<CaptureId, FlowCaptureKind> lValueFlowCaptures; 53 bool IsLValueFlowCapture (CaptureId captureId) 56 bool IsRValueFlowCapture (CaptureId captureId) 64 ImmutableDictionary<CaptureId, FlowCaptureKind> lValueFlowCaptures,
DataFlow\LocalStateLattice.cs (8)
15 readonly CaptureId? CaptureId; 19 public LocalKey (CaptureId captureId) => (Local, CaptureId) = (null, captureId); 46 public DefaultValueDictionary<CaptureId, ValueSet<CapturedReferenceValue>> CapturedReferences; 50 new DefaultValueDictionary<CaptureId, ValueSet<CapturedReferenceValue>> (default (ValueSet<CapturedReferenceValue>))) 54 public LocalState (DefaultValueDictionary<LocalKey, TValue> dictionary, DefaultValueDictionary<CaptureId, ValueSet<CapturedReferenceValue>> capturedReferences) 61 : this (dictionary, new DefaultValueDictionary<CaptureId, ValueSet<CapturedReferenceValue>> (default (ValueSet<CapturedReferenceValue>))) 86 public readonly DictionaryLattice<CaptureId, ValueSet<CapturedReferenceValue>, ValueSetLattice<CapturedReferenceValue>> CapturedReferenceLattice; 91 CapturedReferenceLattice = new DictionaryLattice<CaptureId, ValueSet<CapturedReferenceValue>, ValueSetLattice<CapturedReferenceValue>> (default (ValueSetLattice<CapturedReferenceValue>));
DataFlow\LValueFlowCaptureProvider.cs (7)
23 /// <see cref="CaptureId"/> as this flow capture, dereferences and writes to this location 51 public static ImmutableDictionary<CaptureId, FlowCaptureKind> CreateLValueFlowCaptures (ControlFlowGraph cfg) 60 ImmutableDictionary<CaptureId, FlowCaptureKind>.Builder? lvalueFlowCaptureIdBuilder = null; 61 var rvalueFlowCaptureIds = new HashSet<CaptureId> (); 65 lvalueFlowCaptureIdBuilder ??= ImmutableDictionary.CreateBuilder<CaptureId, FlowCaptureKind> (); 78 var captureId = kvp.Key; 85 return lvalueFlowCaptureIdBuilder != null ? lvalueFlowCaptureIdBuilder.ToImmutable () : ImmutableDictionary<CaptureId, FlowCaptureKind>.Empty;
TrimAnalysis\TrimAnalysisVisitor.cs (1)
51 ImmutableDictionary<CaptureId, FlowCaptureKind> lValueFlowCaptures,
TrimAnalysis\TrimDataFlowAnalysis.cs (1)
63 ImmutableDictionary<CaptureId, FlowCaptureKind> lValueFlowCaptures,
Microsoft.CodeAnalysis (19)
Generated\FlowAnalysis.Generated.cs (2)
31CaptureId Id { get; } 55CaptureId Id { get; }
Generated\Operations.Generated.cs (4)
8814internal FlowCaptureOperation(CaptureId id, IOperation value, SemanticModel? semanticModel, SyntaxNode syntax, bool isImplicit) 8820public CaptureId Id { get; } 8867internal FlowCaptureReferenceOperation(CaptureId id, bool isInitialization, SemanticModel? semanticModel, SyntaxNode syntax, ITypeSymbol? type, ConstantValue? constantValue, bool isImplicit) 8875public CaptureId Id { get; }
Operations\CaptureId.cs (5)
13public readonly struct CaptureId : IEquatable<CaptureId> 24/// Compares <see cref="CaptureId"/>s. 26public bool Equals(CaptureId other) => Value == other.Value; 29public override bool Equals(object? obj) => obj is CaptureId && Equals((CaptureId)obj);
Operations\ControlFlowGraphBuilder.cs (2)
1698/// track <see cref="CaptureId"/>s used by the stack spilling, etc. 1868var idsStillOnTheStack = PooledHashSet<CaptureId>.GetInstance();
Operations\ControlFlowGraphBuilder.RegionBuilder.cs (4)
25public ArrayBuilder<CaptureId>? CaptureIds = null; 70CaptureIds = ArrayBuilder<CaptureId>.GetInstance(); 76public void AddCaptureIds(ArrayBuilder<CaptureId>? others) 87CaptureIds = ArrayBuilder<CaptureId>.GetInstance();
Operations\ControlFlowRegion.cs (2)
61public ImmutableArray<CaptureId> CaptureIds { get; } 67ImmutableArray<CaptureId> captureIds,
Microsoft.CodeAnalysis.CodeStyle (23)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\LValueFlowCaptureProvider.cs (6)
22/// <see cref="CaptureId"/> as this flow capture, dereferences and writes to this location 40public static ImmutableDictionary<CaptureId, FlowCaptureKind> CreateLValueFlowCaptures(ControlFlowGraph cfg) 49ImmutableDictionary<CaptureId, FlowCaptureKind>.Builder lvalueFlowCaptureIdBuilder = null; 50var rvalueFlowCaptureIds = PooledHashSet<CaptureId>.GetInstance(); 60lvalueFlowCaptureIdBuilder ??= ImmutableDictionary.CreateBuilder<CaptureId, FlowCaptureKind>(); 80return lvalueFlowCaptureIdBuilder != null ? lvalueFlowCaptureIdBuilder.ToImmutable() : ImmutableDictionary<CaptureId, FlowCaptureKind>.Empty;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.AnalysisData.cs (4)
130public abstract bool IsLValueFlowCapture(CaptureId captureId); 131public abstract bool IsRValueFlowCapture(CaptureId captureId); 132public abstract void OnLValueCaptureFound(ISymbol symbol, IOperation operation, CaptureId captureId); 133public abstract void OnLValueDereferenceFound(CaptureId captureId);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (7)
41private readonly PooledDictionary<CaptureId, PooledHashSet<(ISymbol, IOperation)>> _lValueFlowCapturesMap; 99_lValueFlowCapturesMap = PooledDictionary<CaptureId, PooledHashSet<(ISymbol, IOperation)>>.GetInstance(); 181public ImmutableDictionary<CaptureId, FlowCaptureKind> LValueFlowCapturesInGraph { get; } 457public override bool IsLValueFlowCapture(CaptureId captureId) 460public override bool IsRValueFlowCapture(CaptureId captureId) 463public override void OnLValueCaptureFound(ISymbol symbol, IOperation operation, CaptureId captureId) 474public override void OnLValueDereferenceFound(CaptureId captureId)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.OperationTreeAnalysisData.cs (4)
62public override bool IsLValueFlowCapture(CaptureId captureId) 64public override bool IsRValueFlowCapture(CaptureId captureId) 66public override void OnLValueCaptureFound(ISymbol symbol, IOperation operation, CaptureId captureId) 68public override void OnLValueDereferenceFound(CaptureId captureId)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.Walker.cs (2)
102private void OnLValueCaptureFound(ISymbol symbol, IOperation operation, CaptureId captureId) 105private void OnLValueDereferenceFound(CaptureId captureId)
Microsoft.CodeAnalysis.Test.Utilities (33)
Compilation\ControlFlowGraphVerifier.cs (33)
120var referencedCaptureIds = PooledHashSet<CaptureId>.GetInstance(); 382var longLivedIds = PooledHashSet<CaptureId>.GetInstance(); 383var referencedIds = PooledHashSet<CaptureId>.GetInstance(); 384var entryStates = ArrayBuilder<PooledHashSet<CaptureId>>.GetInstance(blocks.Length, fillWithValue: null); 390PooledHashSet<CaptureId> currentState = entryStates[i] ?? PooledHashSet<CaptureId>.GetInstance(); 401foreach (CaptureId id in region.CaptureIds) 446foreach (PooledHashSet<CaptureId> state in entryStates) 457void verifyLeftRegions(BasicBlock block, PooledHashSet<CaptureId> longLivedIds, PooledHashSet<CaptureId> referencedIds, ArrayBuilder<ControlFlowRegion> regions, Func<string> finalGraph) 491var referencedInLastOperation = PooledHashSet<CaptureId>.GetInstance(); 503foreach (CaptureId id in region.CaptureIds) 534bool isWithStatementTargetCapture(ControlFlowRegion region, BasicBlock block, CaptureId id) 561bool isConditionalXMLAccessReceiverCapture(ControlFlowRegion region, BasicBlock block, CaptureId id) 600bool isSwitchTargetCapture(ControlFlowRegion region, BasicBlock block, CaptureId id) 643bool isForEachEnumeratorCapture(ControlFlowRegion region, BasicBlock block, CaptureId id) 681bool isAggregateGroupCapture(IOperation operation, ControlFlowRegion region, BasicBlock block, CaptureId id) 713void adjustEntryStateForDestination(ArrayBuilder<PooledHashSet<CaptureId>> entryStates, ControlFlowBranch branch, PooledHashSet<CaptureId> state) 719PooledHashSet<CaptureId> entryState = adjustAndGetEntryState(entryStates, branch.Destination, state); 752PooledHashSet<CaptureId> adjustAndGetEntryState(ArrayBuilder<PooledHashSet<CaptureId>> entryStates, BasicBlock block, PooledHashSet<CaptureId> state) 754PooledHashSet<CaptureId> entryState = entryStates[block.Ordinal]; 757entryState = PooledHashSet<CaptureId>.GetInstance(); 770PooledHashSet<CaptureId> state, IOperation operation, BasicBlock block, int operationIndex, 771PooledHashSet<CaptureId> longLivedIds, PooledHashSet<CaptureId> referencedIds, Func<string> finalGraph) 775CaptureId id = reference.Id; 1021bool isCaptureFromEnclosingGraph(CaptureId id) 1038bool isConditionalAccessCaptureUsedAfterNullCheck(IOperation operation, ControlFlowRegion region, BasicBlock block, CaptureId id) 1405foreach (CaptureId id in region.CaptureIds) 1675foreach (CaptureId id in region.CaptureIds)
Microsoft.CodeAnalysis.Workspaces (23)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\LValueFlowCaptureProvider.cs (6)
22/// <see cref="CaptureId"/> as this flow capture, dereferences and writes to this location 40public static ImmutableDictionary<CaptureId, FlowCaptureKind> CreateLValueFlowCaptures(ControlFlowGraph cfg) 49ImmutableDictionary<CaptureId, FlowCaptureKind>.Builder lvalueFlowCaptureIdBuilder = null; 50var rvalueFlowCaptureIds = PooledHashSet<CaptureId>.GetInstance(); 60lvalueFlowCaptureIdBuilder ??= ImmutableDictionary.CreateBuilder<CaptureId, FlowCaptureKind>(); 80return lvalueFlowCaptureIdBuilder != null ? lvalueFlowCaptureIdBuilder.ToImmutable() : ImmutableDictionary<CaptureId, FlowCaptureKind>.Empty;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.AnalysisData.cs (4)
130public abstract bool IsLValueFlowCapture(CaptureId captureId); 131public abstract bool IsRValueFlowCapture(CaptureId captureId); 132public abstract void OnLValueCaptureFound(ISymbol symbol, IOperation operation, CaptureId captureId); 133public abstract void OnLValueDereferenceFound(CaptureId captureId);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (7)
41private readonly PooledDictionary<CaptureId, PooledHashSet<(ISymbol, IOperation)>> _lValueFlowCapturesMap; 99_lValueFlowCapturesMap = PooledDictionary<CaptureId, PooledHashSet<(ISymbol, IOperation)>>.GetInstance(); 181public ImmutableDictionary<CaptureId, FlowCaptureKind> LValueFlowCapturesInGraph { get; } 457public override bool IsLValueFlowCapture(CaptureId captureId) 460public override bool IsRValueFlowCapture(CaptureId captureId) 463public override void OnLValueCaptureFound(ISymbol symbol, IOperation operation, CaptureId captureId) 474public override void OnLValueDereferenceFound(CaptureId captureId)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.OperationTreeAnalysisData.cs (4)
62public override bool IsLValueFlowCapture(CaptureId captureId) 64public override bool IsRValueFlowCapture(CaptureId captureId) 66public override void OnLValueCaptureFound(ISymbol symbol, IOperation operation, CaptureId captureId) 68public override void OnLValueDereferenceFound(CaptureId captureId)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.Walker.cs (2)
102private void OnLValueCaptureFound(ISymbol symbol, IOperation operation, CaptureId captureId) 105private void OnLValueDereferenceFound(CaptureId captureId)