103 references to GetRequiredSyntaxRootAsync
Microsoft.CodeAnalysis.CodeStyle.Fixes (65)
src\Analyzers\Core\CodeFixes\AddAnonymousTypeMemberName\AbstractAddAnonymousTypeMemberNameCodeFixProvider.cs (1)
56var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\AddExplicitCast\AbstractAddExplicitCastCodeFixProvider.cs (2)
73var root = await document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false); 218var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\AddObsoleteAttribute\AbstractAddObsoleteAttributeCodeFixProvider.cs (2)
43var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 79var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\AddParameter\AbstractAddParameterCodeFixProvider.cs (1)
68var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\AddParameter\AddParameterService.cs (2)
113var syntaxRoot = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 183var rewrittenSyntaxRoot = await rewrittenDocument.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\AliasAmbiguousType\AbstractAliasAmbiguousTypeCodeFixProvider.cs (1)
34var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\ConflictMarkerResolution\AbstractConflictMarkerCodeFixProvider.cs (2)
74var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 406var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\ConvertToAsync\AbstractConvertToAsyncCodeFixProvider.cs (1)
23var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\DocumentationComments\AbstractAddDocCommentNodesCodeFixProvider.cs (2)
31var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false); 60var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\DocumentationComments\AbstractRemoveDocCommentNodeCodeFixProvider.cs (2)
35var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false); 61var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\Formatting\FormattingCodeFixProvider.cs (1)
72var root = await context.Document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\GenerateDefaultConstructors\AbstractGenerateDefaultConstructorCodeFixProvider.cs (1)
28var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\GenerateMember\AbstractGenerateMemberCodeFixProvider.cs (1)
41var root = await document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\ImplementAbstractClass\AbstractImplementAbstractClassCodeFixProvider.cs (1)
28var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\ImplementAbstractClass\ImplementAbstractClassData.cs (1)
114var root = await _document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\ImplementInterface\AbstractImplementInterfaceCodeFixProvider.cs (1)
24var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\ImplementInterface\ImplementInterfaceGenerator_DisposePattern.cs (2)
60var rootWithCoreMembers = await docWithCoreMembers.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 91var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\Iterator\AbstractIteratorCodeFixProvider.cs (1)
21var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\MakeFieldReadonly\AbstractMakeFieldReadonlyCodeFixProvider.cs (1)
44var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\MakeMethodAsynchronous\AbstractMakeMethodAsynchronousCodeFixProvider.cs (1)
177var newRoot = await newDocument.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\MakeMethodSynchronous\AbstractMakeMethodSynchronousCodeFixProvider.cs (3)
106var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 122var syntaxRoot = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 175var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\NamingStyle\NamingStyleCodeFixProvider.cs (1)
57var root = await document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\NewLines\ConsecutiveStatementPlacement\ConsecutiveStatementPlacementCodeFixProvider.cs (1)
46var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\NewLines\MultipleBlankLines\AbstractMultipleBlankLinesCodeFixProvider.cs (1)
48var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\RemoveRedundantEquality\RemoveRedundantEqualityCodeFixProvider.cs (1)
36var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\RemoveUnnecessaryImports\AbstractRemoveUnnecessaryImportsCodeFixProvider.cs (1)
57var newRoot = await newDocument.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\RemoveUnnecessarySuppressions\RemoveUnnecessaryAttributeSuppressionsCodeFixProvider.cs (1)
28var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\RemoveUnnecessarySuppressions\RemoveUnnecessaryPragmaSuppressionsCodeFixProvider.cs (1)
32var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\RemoveUnusedParametersAndValues\AbstractRemoveUnusedValuesCodeFixProvider.cs (6)
164var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false); 278var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 298var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 784var newRoot = await newDocument.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 843var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 885root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\UnsealClass\AbstractUnsealClassCodeFixProvider.cs (2)
34var syntaxRoot = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 64var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\UpdateLegacySuppressions\UpdateLegacySuppressionsCodeFixProvider.cs (1)
29var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\UseAutoProperty\AbstractUseAutoPropertyCodeFixProvider.cs (4)
246var declaratorTreeRoot = await fieldDocument.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 260var fieldTreeRoot = await fieldDocument.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 261var propertyTreeRoot = await propertyDocument.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 440return await cleanedDocument.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\UseConditionalExpression\AbstractUseConditionalExpressionCodeFixProvider.cs (1)
48var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\UseObjectInitializer\AbstractUseObjectInitializerCodeFixProvider.cs (1)
72var currentRoot = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixes\SyntaxEditorBasedCodeFixProvider.cs (1)
83var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeFixesAndRefactorings\AbstractFixAllSpanMappingService.cs (1)
78var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Editing\ImportAdderService.cs (3)
37var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 120var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 180var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\DocumentExtensions.cs (1)
132var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Formatting\FormatterShared.cs (1)
26var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\InitializeParameter\AbstractInitializerParameterService.cs (1)
123var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Simplification\AbstractSimplificationService.cs (2)
96var root = (TCompilationUnitSyntax)await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 107root = (TCompilationUnitSyntax)await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Utilities\ParsedDocument.cs (1)
34var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Utilities\SemanticDocument.cs (1)
21var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Utilities\SyntacticDocument.cs (1)
31var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (38)
src\Analyzers\CSharp\CodeFixes\AddInheritdoc\AddInheritdocCodeFixProvider.cs (1)
40var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\AssignOutParameters\AbstractAssignOutParametersCodeFixProvider.cs (2)
32var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 97var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\ConditionalExpressionInStringInterpolation\CSharpAddParenthesesAroundConditionalExpressionInInterpolatedStringCodeFixProvider.cs (3)
35var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false); 66var syntaxRoot = await documentWithOpenParenthesis.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 117var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\ConvertNamespace\ConvertNamespaceCodeFixProvider.cs (1)
63await converted.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false));
src\Analyzers\CSharp\CodeFixes\ConvertToRecord\CSharpConvertToRecordCodeFixProvider.cs (1)
36var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\GenerateMethod\GenerateDeconstructMethodCodeFixProvider.cs (1)
41var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\HideBase\HideBaseCodeFixProvider.AddNewKeywordAction.cs (1)
25var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\HideBase\HideBaseCodeFixProvider.cs (1)
45var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\MakeLocalFunctionStatic\MakeLocalFunctionStaticCodeFixHelper.cs (2)
32var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 45var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\MakeLocalFunctionStatic\PassInCapturedVariablesAsArgumentsCodeFixProvider.cs (1)
68var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\MakeMemberRequired\CSharpMakeMemberRequiredCodeFixProvider.cs (1)
37var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\MakeRefStruct\MakeRefStructCodeFixProvider.cs (2)
41var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 68var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\MakeStatementAsynchronous\CSharpMakeStatementAsynchronousCodeFixProvider.cs (1)
35var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\MisplacedUsingDirectives\MisplacedUsingDirectivesCodeFixProvider.cs (2)
62var syntaxRoot = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 90var compilationUnit = (CompilationUnitSyntax)await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\NewLines\ArrowExpressionClausePlacement\ArrowExpressionClausePlacementCodeFixProvider.cs (1)
47var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\NewLines\ConditionalExpressionPlacement\ConditionalExpressionPlacementCodeFixProvider.cs (1)
47var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\NewLines\ConsecutiveBracePlacement\ConsecutiveBracePlacementCodeFixProvider.cs (1)
50var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\NewLines\ConstructorInitializerPlacement\ConstructorInitializerPlacementCodeFixProvider.cs (1)
47var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\NewLines\EmbeddedStatementPlacement\EmbeddedStatementPlacementCodeFixProvider.cs (1)
48var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\RemoveConfusingSuppression\CSharpRemoveConfusingSuppressionCodeFixProvider.cs (1)
61var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\RemoveInKeyword\RemoveInKeywordCodeFixProvider.cs (2)
35var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false); 59var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\RemoveNewModifier\RemoveNewModifierCodeFixProvider.cs (2)
33var root = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false); 62var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\ReplaceDefaultLiteral\CSharpReplaceDefaultLiteralCodeFixProvider.cs (2)
40var syntaxRoot = await context.Document.GetRequiredSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false); 67var syntaxRoot = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpUseCollectionExpressionForBuilderCodeFixProvider.cs (2)
58var root = await newDocument.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 113var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\UseExplicitTypeForConst\UseExplicitTypeForConstCodeFixProvider.cs (2)
39var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false); 64var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeFixesAndRefactorings\CSharpFixAllSpanMappingService.cs (1)
27var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpRemoveUnnecessaryImportsService.cs (1)
52var root = await document.GetRequiredSyntaxRootAsync(cancellationToken).ConfigureAwait(false);