Skip to content

Commit

Permalink
Fix comment
Browse files Browse the repository at this point in the history
  • Loading branch information
CyrusNajmabadi committed Jun 11, 2021
1 parent 045ec68 commit d0ff965
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,8 @@ public static async ValueTask<ImmutableArray<UnifiedSuggestedActionSet>> GetFilt
Func<string, IDisposable?> addOperationScope,
CancellationToken cancellationToken)
{
// It may seem strange that we kick off a task, but then immediately 'Wait' on
// it. However, it's deliberate. We want to make sure that the code runs on
// the background so that no one takes an accidentally dependency on running on
// the UI thread.
// Intentionally switch to a threadpool thread to compute fixes. We do not want to accidentally
// run any of this on the UI thread and potentially allow any code to take a dependency on that.
var fixes = await Task.Run(() => codeFixService.GetFixesAsync(
document, selection, includeSuppressionFixes: true, isBlocking, addOperationScope, cancellationToken), cancellationToken).ConfigureAwait(false);

Expand Down

0 comments on commit d0ff965

Please sign in to comment.