35 references to UsingKeyword
Microsoft.CodeAnalysis.CSharp (11)
Binder\UsingStatementBinder.cs (1)
84var boundUsingStatement = BindUsingStatementOrDeclarationFromParts((CSharpSyntaxNode)expressionSyntax ?? declarationSyntax, _syntax.UsingKeyword, _syntax.AwaitKeyword, originalBinder, this, diagnostics);
Syntax.xml.Main.Generated.cs (1)
1900=> node.Update(VisitList(node.AttributeLists), VisitToken(node.AwaitKeyword), VisitToken(node.UsingKeyword), VisitToken(node.OpenParenToken), (VariableDeclarationSyntax?)Visit(node.Declaration), (ExpressionSyntax?)Visit(node.Expression), VisitToken(node.CloseParenToken), (StatementSyntax?)Visit(node.Statement) ?? throw new ArgumentNullException("statement"));
Syntax.xml.Syntax.Generated.cs (8)
7992if (attributeLists != this.AttributeLists || awaitKeyword != this.AwaitKeyword || usingKeyword != this.UsingKeyword || openParenToken != this.OpenParenToken || declaration != this.Declaration || expression != this.Expression || closeParenToken != this.CloseParenToken || statement != this.Statement) 8003public new UsingStatementSyntax WithAttributeLists(SyntaxList<AttributeListSyntax> attributeLists) => Update(attributeLists, this.AwaitKeyword, this.UsingKeyword, this.OpenParenToken, this.Declaration, this.Expression, this.CloseParenToken, this.Statement); 8004public UsingStatementSyntax WithAwaitKeyword(SyntaxToken awaitKeyword) => Update(this.AttributeLists, awaitKeyword, this.UsingKeyword, this.OpenParenToken, this.Declaration, this.Expression, this.CloseParenToken, this.Statement); 8006public UsingStatementSyntax WithOpenParenToken(SyntaxToken openParenToken) => Update(this.AttributeLists, this.AwaitKeyword, this.UsingKeyword, openParenToken, this.Declaration, this.Expression, this.CloseParenToken, this.Statement); 8007public UsingStatementSyntax WithDeclaration(VariableDeclarationSyntax? declaration) => Update(this.AttributeLists, this.AwaitKeyword, this.UsingKeyword, this.OpenParenToken, declaration, this.Expression, this.CloseParenToken, this.Statement); 8008public UsingStatementSyntax WithExpression(ExpressionSyntax? expression) => Update(this.AttributeLists, this.AwaitKeyword, this.UsingKeyword, this.OpenParenToken, this.Declaration, expression, this.CloseParenToken, this.Statement); 8009public UsingStatementSyntax WithCloseParenToken(SyntaxToken closeParenToken) => Update(this.AttributeLists, this.AwaitKeyword, this.UsingKeyword, this.OpenParenToken, this.Declaration, this.Expression, closeParenToken, this.Statement); 8010public UsingStatementSyntax WithStatement(StatementSyntax statement) => Update(this.AttributeLists, this.AwaitKeyword, this.UsingKeyword, this.OpenParenToken, this.Declaration, this.Expression, this.CloseParenToken, statement);
Syntax\LookupPosition.cs (1)
359return ((UsingStatementSyntax)statement).UsingKeyword;
Microsoft.CodeAnalysis.CSharp.CodeStyle (1)
src\Analyzers\CSharp\Analyzers\UseSimpleUsingStatement\UseSimpleUsingStatementDiagnosticAnalyzer.cs (1)
125outermostUsing.UsingKeyword.GetLocation(),
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (2)
src\Analyzers\CSharp\CodeFixes\MakeStatementAsynchronous\CSharpMakeStatementAsynchronousCodeFixProvider.cs (1)
81.WithUsingKeyword(usingStatement.UsingKeyword.WithLeadingTrivia())
src\Analyzers\CSharp\CodeFixes\UseSimpleUsingStatement\UseSimpleUsingStatementCodeFixProvider.cs (1)
200usingStatement.UsingKeyword.WithAppendedTrailingTrivia(ElasticMarker),
Microsoft.CodeAnalysis.CSharp.Features (5)
EditAndContinue\CSharpEditAndContinueAnalyzer.cs (1)
1763return TextSpan.FromBounds(usingStatement.UsingKeyword.SpanStart, usingStatement.CloseParenToken.Span.End);
Highlighting\KeywordHighlighters\UsingStatementHighlighter.cs (1)
28=> highlights.Add(usingStatement.UsingKeyword.Span);
src\Analyzers\CSharp\Analyzers\UseSimpleUsingStatement\UseSimpleUsingStatementDiagnosticAnalyzer.cs (1)
125outermostUsing.UsingKeyword.GetLocation(),
src\Analyzers\CSharp\CodeFixes\MakeStatementAsynchronous\CSharpMakeStatementAsynchronousCodeFixProvider.cs (1)
81.WithUsingKeyword(usingStatement.UsingKeyword.WithLeadingTrivia())
src\Analyzers\CSharp\CodeFixes\UseSimpleUsingStatement\UseSimpleUsingStatementCodeFixProvider.cs (1)
200usingStatement.UsingKeyword.WithAppendedTrailingTrivia(ElasticMarker),
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (16)
Generated\Syntax.Test.xml.Generated.cs (2)
12700Assert.Equal(SyntaxKind.UsingKeyword, node.UsingKeyword.Kind()); 12706var newNode = node.WithAttributeLists(node.AttributeLists).WithAwaitKeyword(node.AwaitKeyword).WithUsingKeyword(node.UsingKeyword).WithOpenParenToken(node.OpenParenToken).WithDeclaration(node.Declaration).WithExpression(node.Expression).WithCloseParenToken(node.CloseParenToken).WithStatement(node.Statement);
Parsing\StatementParsingTests.cs (14)
2345Assert.NotEqual(default, us.UsingKeyword); 2346Assert.Equal(SyntaxKind.UsingKeyword, us.UsingKeyword.Kind()); 2367Assert.NotEqual(default, us.UsingKeyword); 2368Assert.Equal(SyntaxKind.UsingKeyword, us.UsingKeyword.Kind()); 2460Assert.NotEqual(default, us.UsingKeyword); 2461Assert.Equal(SyntaxKind.UsingKeyword, us.UsingKeyword.Kind()); 2800Assert.NotEqual(default, us.UsingKeyword); 2801Assert.Equal(SyntaxKind.UsingKeyword, us.UsingKeyword.Kind()); 2925Assert.NotEqual(default, us.UsingKeyword); 2926Assert.Equal(SyntaxKind.UsingKeyword, us.UsingKeyword.Kind()); 3008Assert.NotEqual(default, us.UsingKeyword); 3009Assert.Equal(SyntaxKind.UsingKeyword, us.UsingKeyword.Kind()); 3080Assert.NotEqual(default, us.UsingKeyword); 3081Assert.Equal(SyntaxKind.UsingKeyword, us.UsingKeyword.Kind());