1 write to _diagnosticContext
ILLink.RoslynAnalyzer (1)
TrimAnalysis\HandleCallAction.cs (1)
40
_diagnosticContext
= new DiagnosticContext(location, reportDiagnostic);
23 references to _diagnosticContext
ILLink.RoslynAnalyzer (23)
src\tools\illink\src\ILLink.Shared\TrimAnalysis\HandleCallAction.cs (13)
380
_diagnosticContext
.AddDiagnostic(DiagnosticId.UnrecognizedTypeInRuntimeHelpersRunClassConstructor, calledMethod.GetDisplayName());
884
_diagnosticContext
.AddDiagnostic(DiagnosticId.PropertyAccessorParameterInLinqExpressionsCannotBeStaticallyDetermined,
981
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericMethod, calledMethod.GetDisplayName());
994
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericMethod, calledMethod.GetDisplayName());
1053
_diagnosticContext
.AddDiagnostic(DiagnosticId.CaseInsensitiveTypeGetTypeCallIsNotSupported, calledMethod.GetDisplayName());
1085
_diagnosticContext
.AddDiagnostic(DiagnosticId.UnrecognizedTypeNameInTypeGetType, calledMethod.GetDisplayName());
1165
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericType, calledMethod.GetDisplayName());
1177
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericType, calledMethod.GetDisplayName());
1364
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericMethod, calledMethod.GetDisplayName());
1519
_diagnosticContext
.AddDiagnostic(DiagnosticId.ParametersOfAssemblyCreateInstanceCannotBeAnalyzed, calledMethod.GetDisplayName());
1657
_diagnosticContext
.AddDiagnostic(DiagnosticId.MakeGenericMethod, reflectionMethod.GetDisplayName());
1720
_diagnosticContext
.AddDiagnostic(DiagnosticId.UnrecognizedParameterInMethodCreateInstance, new ParameterProxy(calledMethod, (ParameterIndex)1 + offset).GetDisplayName(), calledMethod.GetDisplayName());
1726
_diagnosticContext
.AddDiagnostic(DiagnosticId.UnrecognizedParameterInMethodCreateInstance, new ParameterProxy(calledMethod, (ParameterIndex)0 + offset).GetDisplayName(), calledMethod.GetDisplayName());
TrimAnalysis\HandleCallAction.cs (10)
43
_requireDynamicallyAccessedMembersAction = new(
_diagnosticContext
, _reflectionAccessAnalyzer);
200
_diagnosticContext
.AddDiagnostic(DiagnosticId.TypeMapGroupTypeCannotBeStaticallyDetermined,
287
=> _reflectionAccessAnalyzer.GetReflectionAccessDiagnosticsForConstructorsOnType(
_diagnosticContext
.Location, type.Type, BindingFlags.Static, parameterCount: 0);
290
=> _reflectionAccessAnalyzer.GetReflectionAccessDiagnosticsForEventsOnTypeHierarchy(
_diagnosticContext
.Location, type.Type, name, bindingFlags);
293
=> _reflectionAccessAnalyzer.GetReflectionAccessDiagnosticsForFieldsOnTypeHierarchy(
_diagnosticContext
.Location, type.Type, name, bindingFlags);
296
=> _reflectionAccessAnalyzer.GetReflectionAccessDiagnosticsForPropertiesOnTypeHierarchy(
_diagnosticContext
.Location, type.Type, name, bindingFlags);
299
=> _reflectionAccessAnalyzer.GetReflectionAccessDiagnosticsForPublicParameterlessConstructor(
_diagnosticContext
.Location, type.Type);
302
=> _reflectionAccessAnalyzer.GetReflectionAccessDiagnosticsForConstructorsOnType(
_diagnosticContext
.Location, type.Type, bindingFlags, parameterCount);
305
=> _reflectionAccessAnalyzer.GetReflectionAccessDiagnosticsForMethod(
_diagnosticContext
.Location, method.Method);
316
_reflectionAccessAnalyzer.GetReflectionAccessDiagnosticsForProperty(
_diagnosticContext
.Location, property!);