28 references to AddDiagnostic
ILLink.RoslynAnalyzer (28)
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\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());
src\runtime\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 (2)
205_diagnosticContext.AddDiagnostic(DiagnosticId.TypeMapGroupTypeCannotBeStaticallyDetermined, 323_diagnosticContext.AddDiagnostic(DiagnosticId.RequiresUnreferencedCode, calledMethod.GetDisplayName(), message, url);
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);