1 write to _diagnosticContext
ILCompiler.Compiler (1)
Compiler\Dataflow\HandleCallAction.cs (1)
44
_diagnosticContext
= diagnosticContext;
42 references to _diagnosticContext
ILCompiler.Compiler (42)
Compiler\Dataflow\HandleCallAction.cs (29)
86
_reflectionMarker.MarkType(
_diagnosticContext
.Origin, typeInstantiated, "MakeGenericType");
110
_reflectionMarker.MarkType(
_diagnosticContext
.Origin, typeInstantiated, "MakeGenericType");
127
ReflectionMethodBodyScanner.CheckAndReportRequires(
_diagnosticContext
, calledMethod.Method, DiagnosticUtilities.RequiresDynamicCodeAttribute);
159
_reflectionMarker.MarkMethod(
_diagnosticContext
.Origin, methodInstantiated, "MakeGenericMethod");
191
ReflectionMethodBodyScanner.CheckAndReportRequires(
_diagnosticContext
, calledMethod.Method, DiagnosticUtilities.RequiresDynamicCodeAttribute);
204
_diagnosticContext
.AddDiagnostic(DiagnosticId.CorrectnessOfAbstractDelegatesCannotBeGuaranteed, calledMethod.GetDisplayName());
209
_diagnosticContext
.AddDiagnostic(DiagnosticId.CorrectnessOfCOMCannotBeGuaranteed, calledMethod.GetDisplayName());
213
ReflectionMethodBodyScanner.CheckAndReportAllRequires(
_diagnosticContext
, calledMethod.Method);
242
_reflectionMarker.MarkType(
_diagnosticContext
.Origin, canonArrayType, "Array.CreateInstance was called");
271
ReflectionMethodBodyScanner.CheckAndReportRequires(
_diagnosticContext
, calledMethod.Method, DiagnosticUtilities.RequiresDynamicCodeAttribute);
313
ReflectionMethodBodyScanner.CheckAndReportRequires(
_diagnosticContext
, calledMethod.Method, DiagnosticUtilities.RequiresDynamicCodeAttribute);
340
ReflectionMethodBodyScanner.CheckAndReportRequires(
_diagnosticContext
, calledMethod.Method, DiagnosticUtilities.RequiresDynamicCodeAttribute);
497
_diagnosticContext
.AddDiagnostic(DiagnosticId.AvoidAssemblyLocationInSingleFile, calledMethod.GetDisplayName());
507
_diagnosticContext
.AddDiagnostic(DiagnosticId.AvoidAssemblyGetFilesInSingleFile, calledMethod.GetDisplayName());
517
_diagnosticContext
.AddDiagnostic(DiagnosticId.TypeMapGroupTypeCannotBeStaticallyDetermined,
535
_diagnosticContext
.AddDiagnostic(DiagnosticId.TypeMapGroupTypeCannotBeStaticallyDetermined,
701
_diagnosticContext
.AddDiagnostic(DiagnosticId.UnresolvedAssemblyInCreateInstance,
708
if (!_reflectionMarker.TryResolveTypeNameAndMark(resolvedAssembly, typeName,
_diagnosticContext
, "Reflection", fallbackToCoreLib: true, out TypeDesc? foundType))
741
if (!_reflectionMarker.TryResolveTypeNameAndMark(resolvedAssembly, typeName,
_diagnosticContext
, "Reflection", fallbackToCoreLib: false, out TypeDesc? foundType))
752
=> _reflectionMarker.MarkStaticConstructor(
_diagnosticContext
.Origin, type.Type, _reason);
755
=> ReflectionMethodBodyScanner.CheckAndReportRequires(
_diagnosticContext
, calledMethod.Method, DiagnosticUtilities.RequiresUnreferencedCodeAttribute);
758
=> _reflectionMarker.MarkEventsOnTypeHierarchy(
_diagnosticContext
.Origin, type.Type, e => e.Name == name, _reason, bindingFlags);
761
=> _reflectionMarker.MarkFieldsOnTypeHierarchy(
_diagnosticContext
.Origin, type.Type, f => f.Name.StringEquals(name), _reason, bindingFlags);
764
=> _reflectionMarker.MarkPropertiesOnTypeHierarchy(
_diagnosticContext
.Origin, type.Type, p => p.Name == name, _reason, bindingFlags);
767
=> _reflectionMarker.MarkConstructorsOnType(
_diagnosticContext
.Origin, type.Type, m => m.IsPublic() && !m.HasMetadataParameters(), _reason);
770
=> _reflectionMarker.MarkConstructorsOnType(
_diagnosticContext
.Origin, type.Type, parameterCount == null ? null : m => m.GetMetadataParametersCount() == parameterCount, _reason, bindingFlags);
773
=> _reflectionMarker.MarkMethod(
_diagnosticContext
.Origin, method.Method, _reason);
776
=> _reflectionMarker.MarkType(
_diagnosticContext
.Origin, type.Type, _reason);
786
_reflectionMarker.MarkProperty(
_diagnosticContext
.Origin, propertyDefinition, _reason);
src\runtime\src\tools\illink\src\ILLink.Shared\TrimAnalysis\HandleCallAction.cs (13)
402
_diagnosticContext
.AddDiagnostic(DiagnosticId.UnrecognizedTypeInRuntimeHelpersRunClassConstructor, calledMethod.GetDisplayName());
907
_diagnosticContext
.AddDiagnostic(DiagnosticId.PropertyAccessorParameterInLinqExpressionsCannotBeStaticallyDetermined,
1004
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericMethod, calledMethod.GetDisplayName());
1017
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericMethod, calledMethod.GetDisplayName());
1077
_diagnosticContext
.AddDiagnostic(DiagnosticId.CaseInsensitiveTypeGetTypeCallIsNotSupported, calledMethod.GetDisplayName());
1109
_diagnosticContext
.AddDiagnostic(DiagnosticId.UnrecognizedTypeNameInTypeGetType, calledMethod.GetDisplayName());
1189
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericType, calledMethod.GetDisplayName());
1201
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericType, calledMethod.GetDisplayName());
1388
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericMethod, calledMethod.GetDisplayName());
1543
_diagnosticContext
.AddDiagnostic(DiagnosticId.ParametersOfAssemblyCreateInstanceCannotBeAnalyzed, calledMethod.GetDisplayName());
1744
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericMethod, reflectionMethod.GetDisplayName());
1807
_diagnosticContext
.AddDiagnostic(DiagnosticId.UnrecognizedParameterInMethodCreateInstance, new ParameterProxy(calledMethod, (ParameterIndex)1 + offset).GetDisplayName(), calledMethod.GetDisplayName());
1813
_diagnosticContext
.AddDiagnostic(DiagnosticId.UnrecognizedParameterInMethodCreateInstance, new ParameterProxy(calledMethod, (ParameterIndex)0 + offset).GetDisplayName(), calledMethod.GetDisplayName());