30 references to PrecedenceKind
Microsoft.CodeAnalysis.CodeStyle (30)
src\Analyzers\Core\Analyzers\AddRequiredParentheses\AbstractAddRequiredParenthesesDiagnosticAnalyzer.cs (11)
48
protected static string GetEquivalenceKey(
PrecedenceKind
precedenceKind)
51
PrecedenceKind
.Arithmetic or
PrecedenceKind
.Shift or
PrecedenceKind
.Bitwise => "ArithmeticBinary",
52
PrecedenceKind
.Relational or
PrecedenceKind
.Equality => "RelationalBinary",
53
PrecedenceKind
.Logical or
PrecedenceKind
.Coalesce => "OtherBinary",
54
PrecedenceKind
.Other => "Other",
103
var
childPrecedenceKind = _precedenceService.GetPrecedenceKind(binaryLike);
104
var
parentPrecedenceKind = _precedenceService.GetPrecedenceKind(parentBinaryLike);
src\Analyzers\Core\Analyzers\ParenthesesDiagnosticAnalyzersHelper.cs (9)
24
internal static CodeStyleOption2<ParenthesesPreference> GetLanguageOption(AnalyzerOptionsProvider options,
PrecedenceKind
precedenceKind)
27
PrecedenceKind
.Arithmetic or
PrecedenceKind
.Shift or
PrecedenceKind
.Bitwise => options.ArithmeticBinaryParentheses,
28
PrecedenceKind
.Relational or
PrecedenceKind
.Equality => options.RelationalBinaryParentheses,
29
PrecedenceKind
.Logical or
PrecedenceKind
.Coalesce => options.OtherBinaryParentheses,
30
PrecedenceKind
.Other => options.OtherParentheses,
src\Analyzers\Core\Analyzers\RemoveUnnecessaryParentheses\AbstractRemoveUnnecessaryParenthesesDiagnosticAnalyzer.cs (5)
45
out
PrecedenceKind
precedence, out bool clarifiesPrecedence);
53
out
var
precedence, out var clarifiesPrecedence))
67
case
PrecedenceKind
.Shift:
68
case
PrecedenceKind
.Bitwise:
69
case
PrecedenceKind
.Coalesce:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Services\Precedence\IPrecedenceService.cs (5)
13
/// <see cref="
PrecedenceKind
"/> values. The mapping is language specific.
15
PrecedenceKind
GetPrecedenceKind(int operatorPrecedence);
35
PrecedenceKind
IPrecedenceService.GetPrecedenceKind(int operatorPrecedence)
39
public abstract
PrecedenceKind
GetPrecedenceKind(TOperatorPrecedence operatorPrecedence);
44
public static
PrecedenceKind
GetPrecedenceKind(this IPrecedenceService service, SyntaxNode expression)