42 references to Condition
Microsoft.CodeAnalysis.CSharp (17)
_generated\0\Syntax.xml.Main.Generated.cs (1)
1903=> node.Update(VisitList(node.AttributeLists), VisitToken(node.ForKeyword), VisitToken(node.OpenParenToken), (VariableDeclarationSyntax?)Visit(node.Declaration), VisitList(node.Initializers), VisitToken(node.FirstSemicolonToken), (ExpressionSyntax?)Visit(node.Condition), VisitToken(node.SecondSemicolonToken), VisitList(node.Incrementors), VisitToken(node.CloseParenToken), (StatementSyntax?)Visit(node.Statement) ?? throw new ArgumentNullException("statement"));
_generated\2\Syntax.xml.Syntax.Generated.cs (11)
7693if (attributeLists != this.AttributeLists || forKeyword != this.ForKeyword || openParenToken != this.OpenParenToken || declaration != this.Declaration || initializers != this.Initializers || firstSemicolonToken != this.FirstSemicolonToken || condition != this.Condition || secondSemicolonToken != this.SecondSemicolonToken || incrementors != this.Incrementors || closeParenToken != this.CloseParenToken || statement != this.Statement) 7704public new ForStatementSyntax WithAttributeLists(SyntaxList<AttributeListSyntax> attributeLists) => Update(attributeLists, this.ForKeyword, this.OpenParenToken, this.Declaration, this.Initializers, this.FirstSemicolonToken, this.Condition, this.SecondSemicolonToken, this.Incrementors, this.CloseParenToken, this.Statement); 7705public ForStatementSyntax WithForKeyword(SyntaxToken forKeyword) => Update(this.AttributeLists, forKeyword, this.OpenParenToken, this.Declaration, this.Initializers, this.FirstSemicolonToken, this.Condition, this.SecondSemicolonToken, this.Incrementors, this.CloseParenToken, this.Statement); 7706public ForStatementSyntax WithOpenParenToken(SyntaxToken openParenToken) => Update(this.AttributeLists, this.ForKeyword, openParenToken, this.Declaration, this.Initializers, this.FirstSemicolonToken, this.Condition, this.SecondSemicolonToken, this.Incrementors, this.CloseParenToken, this.Statement); 7707public ForStatementSyntax WithDeclaration(VariableDeclarationSyntax? declaration) => Update(this.AttributeLists, this.ForKeyword, this.OpenParenToken, declaration, this.Initializers, this.FirstSemicolonToken, this.Condition, this.SecondSemicolonToken, this.Incrementors, this.CloseParenToken, this.Statement); 7708public ForStatementSyntax WithInitializers(SeparatedSyntaxList<ExpressionSyntax> initializers) => Update(this.AttributeLists, this.ForKeyword, this.OpenParenToken, this.Declaration, initializers, this.FirstSemicolonToken, this.Condition, this.SecondSemicolonToken, this.Incrementors, this.CloseParenToken, this.Statement); 7709public ForStatementSyntax WithFirstSemicolonToken(SyntaxToken firstSemicolonToken) => Update(this.AttributeLists, this.ForKeyword, this.OpenParenToken, this.Declaration, this.Initializers, firstSemicolonToken, this.Condition, this.SecondSemicolonToken, this.Incrementors, this.CloseParenToken, this.Statement); 7711public ForStatementSyntax WithSecondSemicolonToken(SyntaxToken secondSemicolonToken) => Update(this.AttributeLists, this.ForKeyword, this.OpenParenToken, this.Declaration, this.Initializers, this.FirstSemicolonToken, this.Condition, secondSemicolonToken, this.Incrementors, this.CloseParenToken, this.Statement); 7712public ForStatementSyntax WithIncrementors(SeparatedSyntaxList<ExpressionSyntax> incrementors) => Update(this.AttributeLists, this.ForKeyword, this.OpenParenToken, this.Declaration, this.Initializers, this.FirstSemicolonToken, this.Condition, this.SecondSemicolonToken, incrementors, this.CloseParenToken, this.Statement); 7713public ForStatementSyntax WithCloseParenToken(SyntaxToken closeParenToken) => Update(this.AttributeLists, this.ForKeyword, this.OpenParenToken, this.Declaration, this.Initializers, this.FirstSemicolonToken, this.Condition, this.SecondSemicolonToken, this.Incrementors, closeParenToken, this.Statement); 7714public ForStatementSyntax WithStatement(StatementSyntax statement) => Update(this.AttributeLists, this.ForKeyword, this.OpenParenToken, this.Declaration, this.Initializers, this.FirstSemicolonToken, this.Condition, this.SecondSemicolonToken, this.Incrementors, this.CloseParenToken, statement);
Binder\ForLoopBinder.cs (1)
93ExpressionSyntax conditionSyntax = node.Condition;
Binder\LocalBinderFactory.cs (1)
618ExpressionSyntax condition = node.Condition;
Compilation\MemberSemanticModel.cs (2)
408forStmt.Condition != null) 410binder = binder.GetBinder(forStmt.Condition);
Syntax\SyntaxNodeExtensions.cs (1)
128return forStmt.Condition == expression || forStmt.Incrementors.FirstOrDefault() == expression;
Microsoft.CodeAnalysis.CSharp.CodeStyle (4)
src\roslyn\src\Analyzers\CSharp\Analyzers\UsePatternMatching\CSharpAsAndNullCheckDiagnosticAnalyzer.Analyzer.cs (2)
160if (forStatement.Condition is null || !forStatement.Condition.Span.Contains(_comparison.Span))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\ParenthesizedExpressionSyntaxExtensions.cs (1)
175(nodeParent is ForStatementSyntax forStatement && forStatement.Condition == node) ||
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\SpacingFormattingRule.cs (1)
576=> forStatement is { Initializers.Count: 0, Declaration: null, Condition: null, Incrementors.Count: 0 };
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (1)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpTypeInferenceService.TypeInferrer.cs (1)
1358if (expressionOpt != null && forStatement.Condition != expressionOpt)
Microsoft.CodeAnalysis.CSharp.Features (14)
ConvertForToForEach\CSharpConvertForToForEachCodeRefactoringProvider.cs (2)
52if (forStatement is { Declaration.Variables: [{ Initializer: not null } declarator], Condition.RawKind: (int)SyntaxKind.LessThanExpression, Incrementors.Count: 1 }) 57var binaryExpression = (BinaryExpressionSyntax)forStatement.Condition;
Debugging\CSharpProximityExpressionsService.RelevantExpressionsCollector.cs (1)
58AddExpressionTerms(node.Condition, _expressions);
EditAndContinue\BreakpointSpans.cs (3)
644else if (forStatement.Condition != null) 647return CreateSpan(forStatement.Condition); 984forStatement.Condition == expression ||
EditAndContinue\SyntaxComparer.cs (2)
1179var conditionDistance = ComputeDistance(left.Condition, right.Condition);
ExtractMethod\CSharpMethodExtractor.CSharpCodeGenerator.CallSiteContainerRewriter.cs (1)
243.WithCondition(VisitNode(node.Condition))
ReverseForStatement\CSharpReverseForStatementCodeRefactoringProvider.cs (2)
62if (forStatement.Condition is not BinaryExpressionSyntax condition) 266var condition = (BinaryExpressionSyntax)forStatement.Condition!;
Snippets\AbstractCSharpForLoopSnippetProvider.cs (1)
117var condition = forStatement.Condition;
src\roslyn\src\Analyzers\CSharp\Analyzers\UsePatternMatching\CSharpAsAndNullCheckDiagnosticAnalyzer.Analyzer.cs (2)
160if (forStatement.Condition is null || !forStatement.Condition.Span.Contains(_comparison.Span))
Microsoft.CodeAnalysis.CSharp.Workspaces (3)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\ParenthesizedExpressionSyntaxExtensions.cs (1)
175(nodeParent is ForStatementSyntax forStatement && forStatement.Condition == node) ||
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\SpacingFormattingRule.cs (1)
576=> forStatement is { Initializers.Count: 0, Declaration: null, Condition: null, Incrementors.Count: 0 };
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpTypeInferenceService.TypeInferrer.cs (1)
1358if (expressionOpt != null && forStatement.Condition != expressionOpt)
Roslyn.Diagnostics.CSharp.Analyzers (3)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\ParenthesizedExpressionSyntaxExtensions.cs (1)
175(nodeParent is ForStatementSyntax forStatement && forStatement.Condition == node) ||
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\SpacingFormattingRule.cs (1)
576=> forStatement is { Initializers.Count: 0, Declaration: null, Condition: null, Incrementors.Count: 0 };
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpTypeInferenceService.TypeInferrer.cs (1)
1358if (expressionOpt != null && forStatement.Condition != expressionOpt)