protected override async Task <IEnumerable <CodeActionOperation> > ComputeOperationsAsync(CancellationToken cancellationToken) { cancellationToken.ThrowIfCancellationRequested(); FixAllLogger.LogState(_fixAllState, IsInternalCodeFixProvider(_fixAllState.CodeFixProvider)); var service = _fixAllState.Project.Solution.Workspace.Services.GetService <IFixAllGetFixesService>(); // Use the new cancellation token instead of the stale one present inside _fixAllContext. return(await service.GetFixAllOperationsAsync( _fixAllState.CreateFixAllContext(cancellationToken), _showPreviewChangesDialog).ConfigureAwait(false)); }
internal override Task <ImmutableArray <CodeActionOperation> > ComputeOperationsAsync( IProgressTracker progressTracker, CancellationToken cancellationToken) { cancellationToken.ThrowIfCancellationRequested(); FixAllLogger.LogState(FixAllState, IsInternalCodeFixProvider(FixAllState.CodeFixProvider)); var service = FixAllState.Project.Solution.Workspace.Services.GetService <IFixAllGetFixesService>(); // Use the new cancellation token instead of the stale one present inside _fixAllContext. return(service.GetFixAllOperationsAsync( FixAllState.CreateFixAllContext(progressTracker, cancellationToken), _showPreviewChangesDialog)); }