25 references to proxies
Microsoft.CodeAnalysis.CSharp (25)
Lowering\ClosureConversion\ClosureConversion.cs (9)
41/// variable in the corresponding scope. These are maintained in <see cref="MethodToClassRewriter.proxies"/>. 390Debug.Assert(!proxies.ContainsKey(captured)); 393proxies.Add(captured, new CapturedToFrameSymbolReplacement(hoistedField, isReusable: false)); 620if (proxies.TryGetValue(framePointer, out proxyField)) 688proxies.TryGetValue(_innermostFramePointer, out oldInnermostFrameProxy); 705proxies[_innermostFramePointer] = new CapturedToFrameSymbolReplacement(capturedFrame, isReusable: false); 733proxies[_innermostFramePointer] = oldInnermostFrameProxy; 737proxies.Remove(_innermostFramePointer); 747if (proxies.TryGetValue(symbol, out proxy))
Lowering\MethodToClassRewriter.cs (4)
374if (proxies.TryGetValue(parameterOrLocal, out CapturedSymbolReplacement? proxy)) 429if (proxies.TryGetValue(variable, out CapturedSymbolReplacement? proxy)) 497Debug.Assert(!proxies.ContainsKey(leftLocal.LocalSymbol)); 503if (NeedsProxy(leftLocal.LocalSymbol) && !proxies.ContainsKey(leftLocal.LocalSymbol))
Lowering\StateMachineRewriter\MethodToStateMachineRewriter.cs (12)
135this.proxies.Add(proxy.Key, proxy.Value); 146proxies.TryGetValue(thisParameter, out thisProxy) && 284Debug.Assert(!NeedsProxy(local) || proxies.ContainsKey(local)); 322if (!proxies.TryGetValue(local, out proxy)) 325proxies.Add(local, proxy); 351if (!proxies.TryGetValue(local, out proxy)) 553proxies.Add(local, new CapturedToExpressionSymbolReplacement(replacement, hoistedFields.ToImmutableAndFree(), isReusable: true)); 768hoistedLocalsWithDebugScopes.Add(((CapturedToStateMachineFieldReplacement)proxies[local]).HoistedField); 840if (proxies.ContainsKey(leftLocal)) 946CapturedSymbolReplacement proxy = proxies[this.OriginalMethod.ThisParameter]; 965if ((object)thisParameter == null || !proxies.TryGetValue(thisParameter, out proxy)) 997CapturedSymbolReplacement proxy = proxies[this.OriginalMethod.ThisParameter];