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)
529internal 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; 462var anonymousDelegates = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 463var anonymousDelegatesWithIndexedNames = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 519foreach (var anonymousDelegate in anonymousDelegatesWithIndexedNames) 523foreach (var anonymousDelegate in anonymousDelegates) 579private void GetCreatedAnonymousDelegatesWithIndexedNames(ArrayBuilder<AnonymousDelegateTemplateSymbol> builder) 585foreach (var template in anonymousDelegates.Values) 601private void GetCreatedAnonymousDelegates(ArrayBuilder<AnonymousDelegateTemplateSymbol> builder) 607foreach (var template in delegates.Values) 618private class SynthesizedDelegateSymbolComparer : IComparer<AnonymousDelegateTemplateSymbol> 622public int Compare(AnonymousDelegateTemplateSymbol x, AnonymousDelegateTemplateSymbol y) 630var anonymousDelegates = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 659var templates = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 687var anonymousDelegatesWithIndexedNames = ArrayBuilder<AnonymousDelegateTemplateSymbol>.GetInstance(); 692var 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,