src\Analyzers\CSharp\CodeFixes\ConvertSwitchStatementToExpression\ConvertSwitchStatementToExpressionCodeFixProvider.Rewriter.cs (1)
18using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\InvokeDelegateWithConditionalAccess\InvokeDelegateWithConditionalAccessCodeFixProvider.cs (1)
24using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\NewLines\EmbeddedStatementPlacement\EmbeddedStatementPlacementCodeFixProvider.cs (1)
23using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpUseCollectionExpressionForBuilderCodeFixProvider.cs (1)
25using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpUseCollectionExpressionForCreateCodeFixProvider.cs (1)
23using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpUseCollectionExpressionForFluentCodeFixProvider.cs (1)
32using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseCollectionInitializer\CSharpUseCollectionInitializerCodeFixProvider_CollectionInitializer.cs (1)
21using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseUnboundGenericTypeInNameOf\CSharpUseUnboundGenericTypeInNameOfCodeFixProvider.cs (1)
21using static SyntaxFactory;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ITypeSymbolExtensions.ExpressionSyntaxGeneratorVisitor.cs (1)
12using static SyntaxFactory;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ITypeSymbolExtensions.TypeSyntaxGeneratorVisitor.cs (1)
18using static SyntaxFactory;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpReplaceDiscardDeclarationsWithAssignmentsService.cs (1)
25using static SyntaxFactory;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpSyntaxGeneratorInternal.cs (37)
37=> SyntaxFactory.CarriageReturnLineFeed;
40=> SyntaxFactory.ElasticCarriageReturnLineFeed;
49=> SyntaxFactory.EndOfLine(text);
52=> SyntaxFactory.Comment("//" + text);
56return SyntaxFactory.LocalDeclarationStatement(
65=> SyntaxFactory.EqualsValueClause(operatorToken, (ExpressionSyntax)value);
69return SyntaxFactory.VariableDeclaration(
70type == null ? SyntaxFactory.IdentifierName("var") : (TypeSyntax)type,
71[SyntaxFactory.VariableDeclarator(
73expression == null ? null : SyntaxFactory.EqualsValueClause((ExpressionSyntax)expression))]);
77=> SyntaxFactory.Identifier(identifier);
80=> SyntaxFactory.ConditionalAccessExpression((ExpressionSyntax)expression, (ExpressionSyntax)whenNotNull);
83=> SyntaxFactory.MemberBindingExpression((SimpleNameSyntax)name);
86=> SyntaxFactory.RefExpression((ExpressionSyntax)expression);
100=> SyntaxFactory.YieldStatement(SyntaxKind.YieldReturnStatement, (ExpressionSyntax)expression);
109=> SyntaxFactory.InterpolatedStringExpression(startToken, [.. content.Cast<InterpolatedStringContentSyntax>()], endToken);
112=> SyntaxFactory.InterpolatedStringText(textToken);
115=> SyntaxFactory.Token(
122=> SyntaxFactory.Interpolation((ExpressionSyntax)syntaxNode);
125=> SyntaxFactory.InterpolationAlignmentClause(CommaToken, (ExpressionSyntax)alignment);
128=> SyntaxFactory.InterpolationFormatClause(
130SyntaxFactory.Token(default, SyntaxKind.InterpolatedStringTextToken, format, format, default));
133=> SyntaxFactory.TypeParameterList([.. typeParameterNames.Select(SyntaxFactory.TypeParameter)]);
170=> SyntaxFactory.IsPatternExpression(
176=> SyntaxFactory.BinaryPattern(SyntaxKind.AndPattern, (PatternSyntax)Parenthesize(left), (PatternSyntax)Parenthesize(right));
179=> SyntaxFactory.ConstantPattern((ExpressionSyntax)expression);
182=> SyntaxFactory.DeclarationPattern(
184SyntaxFactory.SingleVariableDesignation(name.ToIdentifierToken()));
187=> SyntaxFactory.RelationalPattern(LessThanToken, (ExpressionSyntax)expression);
190=> SyntaxFactory.RelationalPattern(LessThanEqualsToken, (ExpressionSyntax)expression);
193=> SyntaxFactory.RelationalPattern(GreaterThanToken, (ExpressionSyntax)expression);
196=> SyntaxFactory.RelationalPattern(GreaterThanEqualsToken, (ExpressionSyntax)expression);
199=> SyntaxFactory.UnaryPattern(NotKeyword, (PatternSyntax)Parenthesize(pattern));
202=> SyntaxFactory.BinaryPattern(SyntaxKind.OrPattern, (PatternSyntax)Parenthesize(left), (PatternSyntax)Parenthesize(right));
208=> SyntaxFactory.TypePattern((TypeSyntax)type);
211=> SyntaxFactory.UnaryPattern(operatorToken, (PatternSyntax)Parenthesize(pattern));
ConvertBetweenRegularAndVerbatimString\ConvertBetweenRegularAndVerbatimStringCodeRefactoringProvider.cs (1)
58=> SyntaxFactory.Token(
ConvertPrimaryToRegularConstructor\ConvertPrimaryToRegularConstructorCodeRefactoringProvider_DocumentationComments.cs (1)
15using static SyntaxFactory;
EditAndContinue\SyntaxComparer.cs (10)
728if (!SyntaxFactory.AreEquivalent(leftBody, rightBody, null))
756return SyntaxFactory.AreEquivalent(left, right, ignoreChildFunction);
761return SyntaxFactory.AreEquivalent(left.Labels, right.Labels, null)
762&& SyntaxFactory.AreEquivalent(left.Statements, right.Statements, ignoreChildNode: HasLabel);
1517if (weightedDistance == ExactMatchDist && !SyntaxFactory.AreEquivalent(oldNode, newNode))
1530if (SyntaxFactory.AreEquivalent(oldNode, newNode))
1553Debug.Assert(!SyntaxFactory.AreEquivalent(leftToken, rightToken) || distance == ExactMatchDist);
1561Debug.Assert(!SyntaxFactory.AreEquivalent(leftNode, rightNode) || distance == ExactMatchDist);
1659=> SyntaxFactory.AreEquivalent(oldElement, newElement);
1667=> SyntaxFactory.AreEquivalent(oldElement, newElement);
src\Analyzers\CSharp\Analyzers\UseCollectionExpression\CSharpUseCollectionExpressionForFluentDiagnosticAnalyzer.cs (1)
25using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\ConvertSwitchStatementToExpression\ConvertSwitchStatementToExpressionCodeFixProvider.Rewriter.cs (1)
18using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\InvokeDelegateWithConditionalAccess\InvokeDelegateWithConditionalAccessCodeFixProvider.cs (1)
24using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\NewLines\EmbeddedStatementPlacement\EmbeddedStatementPlacementCodeFixProvider.cs (1)
23using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpUseCollectionExpressionForBuilderCodeFixProvider.cs (1)
25using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpUseCollectionExpressionForCreateCodeFixProvider.cs (1)
23using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpUseCollectionExpressionForFluentCodeFixProvider.cs (1)
32using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseCollectionInitializer\CSharpUseCollectionInitializerCodeFixProvider_CollectionInitializer.cs (1)
21using static SyntaxFactory;
src\Analyzers\CSharp\CodeFixes\UseUnboundGenericTypeInNameOf\CSharpUseUnboundGenericTypeInNameOfCodeFixProvider.cs (1)
21using static SyntaxFactory;