27 references to AddDiagnostic
ILLink.RoslynAnalyzer (27)
RequiresAnalyzerBase.cs (1)
275diagnosticContext.AddDiagnostic(RequiresDiagnosticId, member.GetDisplayName(), message, url);
RequiresAssemblyFilesAnalyzer.cs (2)
117diagnosticContext.AddDiagnostic(DiagnosticId.AvoidAssemblyGetFilesInSingleFile, member.GetDisplayName()); 123diagnosticContext.AddDiagnostic(DiagnosticId.AvoidAssemblyLocationInSingleFile, member.GetDisplayName());
src\tools\illink\src\ILLink.Shared\TrimAnalysis\HandleCallAction.cs (13)
380_diagnosticContext.AddDiagnostic(DiagnosticId.UnrecognizedTypeInRuntimeHelpersRunClassConstructor, calledMethod.GetDisplayName()); 885_diagnosticContext.AddDiagnostic(DiagnosticId.PropertyAccessorParameterInLinqExpressionsCannotBeStaticallyDetermined, 982_diagnosticContext.AddDiagnostic(DiagnosticId.MakeGenericMethod, calledMethod.GetDisplayName()); 995_diagnosticContext.AddDiagnostic(DiagnosticId.MakeGenericMethod, calledMethod.GetDisplayName()); 1055_diagnosticContext.AddDiagnostic(DiagnosticId.CaseInsensitiveTypeGetTypeCallIsNotSupported, calledMethod.GetDisplayName()); 1087_diagnosticContext.AddDiagnostic(DiagnosticId.UnrecognizedTypeNameInTypeGetType, calledMethod.GetDisplayName()); 1167_diagnosticContext.AddDiagnostic(DiagnosticId.MakeGenericType, calledMethod.GetDisplayName()); 1179_diagnosticContext.AddDiagnostic(DiagnosticId.MakeGenericType, calledMethod.GetDisplayName()); 1366_diagnosticContext.AddDiagnostic(DiagnosticId.MakeGenericMethod, calledMethod.GetDisplayName()); 1521_diagnosticContext.AddDiagnostic(DiagnosticId.ParametersOfAssemblyCreateInstanceCannotBeAnalyzed, calledMethod.GetDisplayName()); 1659_diagnosticContext.AddDiagnostic(DiagnosticId.MakeGenericMethod, reflectionMethod.GetDisplayName()); 1722_diagnosticContext.AddDiagnostic(DiagnosticId.UnrecognizedParameterInMethodCreateInstance, new ParameterProxy(calledMethod, (ParameterIndex)1 + offset).GetDisplayName(), calledMethod.GetDisplayName()); 1728_diagnosticContext.AddDiagnostic(DiagnosticId.UnrecognizedParameterInMethodCreateInstance, new ParameterProxy(calledMethod, (ParameterIndex)0 + offset).GetDisplayName(), calledMethod.GetDisplayName());
src\tools\illink\src\ILLink.Shared\TrimAnalysis\RequireDynamicallyAccessedMembersAction.cs (1)
96_diagnosticContext.AddDiagnostic(diagnosticId, targetValue.GetDiagnosticArgumentsForAnnotationMismatch().ToArray());
TrimAnalysis\FeatureCheckReturnValuePattern.cs (2)
43diagnosticContext.AddDiagnostic( 64diagnosticContext.AddDiagnostic(
TrimAnalysis\HandleCallAction.cs (1)
203_diagnosticContext.AddDiagnostic(DiagnosticId.TypeMapGroupTypeCannotBeStaticallyDetermined,
TrimAnalysis\ReflectionAccessAnalyzer.cs (6)
100diagnosticContext.AddDiagnostic(DiagnosticId.RequiresUnreferencedCode, member.GetDisplayName(), message, url); 154diagnosticContext.AddDiagnostic(id, _typeHierarchyType!.GetDisplayName(), 163diagnosticContext.AddDiagnostic(id, _typeHierarchyType!.GetDisplayName(), member.GetDisplayName()); 172diagnosticContext.AddDiagnostic(DiagnosticId.DynamicallyAccessedMembersMethodAccessedViaReflection, methodSymbol.GetDisplayName()); 180diagnosticContext.AddDiagnostic(DiagnosticId.DynamicallyAccessedMembersMethodAccessedViaReflection, methodSymbol.GetDisplayName()); 219diagnosticContext.AddDiagnostic(DiagnosticId.DynamicallyAccessedMembersFieldAccessedViaReflection, fieldSymbol.GetDisplayName());
TrimAnalysis\TypeNameResolver.cs (1)
38diagnosticContext.AddDiagnostic(DiagnosticId.TypeNameIsNotAssemblyQualified, typeNameString);