9 references to _state
Microsoft.CodeAnalysis.CodeStyle.Fixes (9)
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.GenerateLocalCodeAction.cs (9)
32
_state
.IdentifierToken.ValueText);
48
if (_service.TryConvertToLocalDeclaration(
_state
.LocalType,
_state
.IdentifierToken, semanticModel, cancellationToken, out var newRoot))
54
var initializer =
_state
.IsOnlyWrittenTo
56
: syntaxFactory.DefaultExpression(
_state
.LocalType);
58
var type =
_state
.LocalType;
59
var localStatement = syntaxFactory.LocalDeclarationStatement(type,
_state
.IdentifierToken.ValueText, initializer);
62
var root =
_state
.IdentifierToken.GetAncestors<SyntaxNode>().Last();
63
var context = new CodeGenerationContext(beforeThisLocation:
_state
.IdentifierToken.GetLocation());