76 references to Precedence
Microsoft.CodeAnalysis.CSharp (76)
Parser\LanguageParser.cs (61)
4161var refKeyword = this.CurrentToken.Kind == SyntaxKind.RefKeyword && !this.IsPossibleLambdaExpression(Precedence.Expression) 5325var refKeyword = isLocalOrField && !isConst && this.CurrentToken.Kind == SyntaxKind.RefKeyword && !this.IsPossibleLambdaExpression(Precedence.Expression) 9415: this.ParseSubExpression(Precedence.Expression); 9827ParseWhenClause(Precedence.Expression), 10228private WhenClauseSyntax ParseWhenClause(Precedence precedence) 10595return this.ParseSubExpression(Precedence.Expression); 10658return IsPossibleAnonymousMethodExpression() || IsPossibleLambdaExpression(Precedence.Expression); 10749private static Precedence GetPrecedence(SyntaxKind op) 10754return Precedence.Expression; 10758return Precedence.Lambda; 10772return Precedence.Assignment; 10775return Precedence.Coalescing; 10777return Precedence.ConditionalOr; 10779return Precedence.ConditionalAnd; 10781return Precedence.LogicalOr; 10783return Precedence.LogicalXor; 10785return Precedence.LogicalAnd; 10788return Precedence.Equality; 10796return Precedence.Relational; 10799return Precedence.Switch; 10803return Precedence.Shift; 10806return Precedence.Additive; 10810return Precedence.Multiplicative; 10826return Precedence.Unary; 10828return Precedence.Cast; 10830return Precedence.PointerIndirection; 10832return Precedence.AddressOf; 10834return Precedence.Range; 10836return Precedence.Expression; 10875return Precedence.Primary; 10957private ExpressionSyntax ParseSubExpression(Precedence precedence) 10972private ExpressionSyntax ParseSubExpressionCore(Precedence precedence) 10988ExpressionSyntax parseUnaryOrPrimaryExpression(Precedence precedence) 11009? this.ParseSubExpression(Precedence.Range) 11037return precedence <= Precedence.Coalescing 11057private ExpressionSyntax ParseExpressionContinued(ExpressionSyntax unaryOrPrimaryExpression, Precedence precedence) 11077if (this.CurrentToken.Kind == SyntaxKind.QuestionToken && precedence <= Precedence.Conditional) 11082ExpressionSyntax? tryExpandExpression(ExpressionSyntax leftOperand, Precedence precedence) 11093var newPrecedence = GetPrecedence(operatorExpressionKind); 11148? this.ParseSubExpression(Precedence.Range) 11438this.ParseSubExpression(Precedence.Coalescing)); 11452private ExpressionSyntax ParsePrimaryExpression(Precedence precedence) 11461ExpressionSyntax parsePrimaryExpressionWithoutPostfix(Precedence precedence) 11726private bool IsPossibleDeconstructionLeft(Precedence precedence) 11728if (precedence > Precedence.Assignment || !(this.CurrentToken.IsIdentifierVar() || IsPredefinedType(this.CurrentToken.Kind))) 12038this.IsPossibleLambdaExpression(Precedence.Expression))) 12063: ParseSubExpression(Precedence.Expression); 12109this.ParseSubExpression(Precedence.Expression), 12118this.ParseSubExpression(Precedence.Expression), 12132this.ParseSubExpression(Precedence.Expression), 12141this.ParseSubExpression(Precedence.Expression), 12147private bool ScanParenthesizedLambda(Precedence precedence) 12152private bool ScanParenthesizedImplicitlyTypedLambda(Precedence precedence) 12156if (!(precedence <= Precedence.Lambda)) 12237private bool ScanExplicitlyTypedLambda(Precedence precedence) 12241if (!(precedence <= Precedence.Lambda)) 12337this.ParseSubExpression(Precedence.Cast)); 12529private bool IsPossibleLambdaExpression(Precedence precedence) 12531if (precedence > Precedence.Lambda) 13611private QueryExpressionSyntax ParseQueryExpression(Precedence precedence) 13616if (precedence > Precedence.Assignment)
Parser\LanguageParser_Patterns.cs (15)
53private PatternSyntax ParsePattern(Precedence precedence, bool afterIs = false, bool inSwitchArmPattern = false) 58private PatternSyntax ParseDisjunctivePattern(Precedence precedence, bool afterIs, bool inSwitchArmPattern) 104private PatternSyntax ParseConjunctivePattern(Precedence precedence, bool afterIs, bool inSwitchArmPattern) 158private PatternSyntax ParseNegatedPattern(Precedence precedence, bool afterIs, bool inSwitchArmPattern) 172private PatternSyntax ParsePrimaryPattern(Precedence precedence, bool afterIs, bool inSwitchArmPattern) 209Debug.Assert(precedence < Precedence.Shift); 212this.ParseSubExpression(Precedence.Relational)); 242bool CanTokenFollowTypeInPattern(Precedence precedence) 269private PatternSyntax? ParsePatternContinued(TypeSyntax? type, Precedence precedence, bool inSwitchArmPattern) 438var pattern = ParsePattern(Precedence.Conditional, inSwitchArmPattern: true); 507PatternSyntax pattern = ParsePattern(Precedence.Conditional); 516pattern = ParsePattern(Precedence.Conditional); 596var pattern = ParsePattern(Precedence.Coalescing, inSwitchArmPattern: true); 606ParseWhenClause(Precedence.Coalescing), 642static @this => @this.ParsePattern(Precedence.Conditional),