1 write to _localDeclarationStatement
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (1)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpReplaceDiscardDeclarationsWithAssignmentsService.cs (1)
128_localDeclarationStatement = localDeclarationStatement;
9 references to _localDeclarationStatement
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (9)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpReplaceDiscardDeclarationsWithAssignmentsService.cs (9)
158foreach (var variable in _localDeclarationStatement.Declaration.Variables) 192var leadingTrivia = _localDeclarationStatement.Declaration.Type.GetLeadingTrivia() 193.Concat(_localDeclarationStatement.Declaration.Type.GetTrailingTrivia()); 199var trailingTrivia = _localDeclarationStatement.SemicolonToken.GetAllTrivia(); 204if (_localDeclarationStatement.Parent is BlockSyntax or SwitchSectionSyntax) 208_editor.InsertAfter(_localDeclarationStatement, _statementsBuilder.Skip(1)); 211_editor.ReplaceNode(_localDeclarationStatement, _statementsBuilder[0]); 215_editor.ReplaceNode(_localDeclarationStatement, Block(_statementsBuilder)); 229VariableDeclaration(_localDeclarationStatement.Declaration.Type, _currentNonDiscardVariables))