3 instantiations of AnonymousDelegateTemplateSymbol
Microsoft.CodeAnalysis.CSharp (3)
Symbols\AnonymousTypes\AnonymousTypeManager.Templates.cs (3)
168synthesizedDelegate = new AnonymousDelegateTemplateSymbol( 246static (key, @this) => new AnonymousDelegateTemplateSymbol(@this, key.TypeDescriptor), 278template = this.AnonymousDelegates.GetOrAdd(key, new AnonymousDelegateTemplateSymbol(this, typeDescr, typeParameters));
36 references to AnonymousDelegateTemplateSymbol
Microsoft.CodeAnalysis.CSharp (36)
Emitter\EditAndContinue\CSharpSymbolMatcher.cs (6)
102=> _visitor.TryGetMatchingDelegateWithIndexedName((AnonymousTypeManager.AnonymousDelegateTemplateSymbol)delegateTemplate, values, out match); 352else if (sourceType is AnonymousTypeManager.AnonymousDelegateTemplateSymbol delegateTemplate) 481private bool TryGetAnonymousDelegateValue(AnonymousTypeManager.AnonymousDelegateTemplateSymbol delegateSymbol, out SynthesizedDelegateValue otherDelegateSymbol) 494var delegateTemplate = (AnonymousTypeManager.AnonymousDelegateTemplateSymbol)template; 504internal bool TryGetMatchingDelegateWithIndexedName(AnonymousTypeManager.AnonymousDelegateTemplateSymbol delegateTemplate, ImmutableArray<AnonymousTypeValue> values, out AnonymousTypeValue match)
Emitter\Model\PEModuleBuilder.cs (1)
536internal virtual bool TryGetAnonymousDelegateValue(AnonymousTypeManager.AnonymousDelegateTemplateSymbol template, out SynthesizedDelegateValue delegateValue)
Lowering\LocalRewriter\LoweredDynamicOperationFactory.cs (1)
788var synthesizedType = _factory.Compilation.AnonymousTypeManager.SynthesizeDelegate(parameterCount, byRefs, returnsVoid, generation);
Symbols\AnonymousTypes\AnonymousTypeManager.Templates.cs (24)
36private ConcurrentDictionary<SynthesizedDelegateKey, AnonymousDelegateTemplateSymbol>? _lazyAnonymousDelegates; 133private ConcurrentDictionary<SynthesizedDelegateKey, AnonymousDelegateTemplateSymbol> AnonymousDelegates 144? new ConcurrentDictionary<SynthesizedDelegateKey, AnonymousDelegateTemplateSymbol>() 145: new ConcurrentDictionary<SynthesizedDelegateKey, AnonymousDelegateTemplateSymbol>(previousCache), 153internal AnonymousDelegateTemplateSymbol SynthesizeDelegate(int parameterCount, RefKindVector refKinds, bool returnsVoid, int generation) 161AnonymousDelegateTemplateSymbol? synthesizedDelegate; 244var namedTemplate = this.AnonymousDelegates.GetOrAdd( 262var template = SynthesizeDelegate(parameterCount: fields.Length - 1, refKinds, returnsVoid, generation); 275AnonymousDelegateTemplateSymbol? template; 450var anonymousDelegates = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 451var anonymousDelegatesWithIndexedNames = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 510foreach (var anonymousDelegate in anonymousDelegatesWithIndexedNames) 514foreach (var anonymousDelegate in anonymousDelegates) 570private void GetCreatedAnonymousDelegatesWithIndexedNames(ArrayBuilder<AnonymousDelegateTemplateSymbol> builder) 576foreach (var template in anonymousDelegates.Values) 592private void GetCreatedAnonymousDelegates(ArrayBuilder<AnonymousDelegateTemplateSymbol> builder) 598foreach (var template in delegates.Values) 609private class SynthesizedDelegateSymbolComparer : IComparer<AnonymousDelegateTemplateSymbol> 613public int Compare(AnonymousDelegateTemplateSymbol x, AnonymousDelegateTemplateSymbol y) 621var anonymousDelegates = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 650var templates = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 678var anonymousDelegatesWithIndexedNames = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 683var anonymousDelegates = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance();
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.DelegateTemplateSymbol.cs (4)
52static SynthesizedDelegateInvokeMethod createInvokeMethod(AnonymousDelegateTemplateSymbol containingType, RefKindVector refKinds, TypeSymbol? voidReturnTypeOpt) 74private static ImmutableArray<TypeParameterSymbol> CreateTypeParameters(AnonymousDelegateTemplateSymbol containingType, int parameterCount, bool returnsVoid, bool hasParamsArray) 119AnonymousDelegateTemplateSymbol containingType, 193AnonymousDelegateTemplateSymbol containingType,