9 references to CA1857
Microsoft.CodeAnalysis.NetAnalyzers (9)
Microsoft.NetCore.Analyzers\Performance\ConstantExpectedAnalyzer.cs (9)
75internal const string Id = nameof(CA1857); 121CA1857.ConstantOutOfBoundsRule, CA1857.ConstantInvalidConstantRule, 122CA1857.ConstantNotConstantRule, CA1857.AttributeExpectedRule); 250var diagnostic = parameter.DeclaringSyntaxReferences[0].GetSyntax().CreateDiagnostic(CA1857.AttributeExpectedRule); 480validationDiagnostics = argument.CreateDiagnostic(CA1857.ConstantNotConstantRule); 489protected Diagnostic CreateConstantInvalidConstantRuleDiagnostic(IArgumentOperation argument) => argument.CreateDiagnostic(CA1857.ConstantInvalidConstantRule, Parameter.Type.ToDisplayString()); 490protected static Diagnostic CreateConstantOutOfBoundsRuleDiagnostic(IArgumentOperation argument, string minText, string maxText) => argument.CreateDiagnostic(CA1857.ConstantOutOfBoundsRule, minText, maxText);