Skip to content

Analyzer to encourage canceling work on shutdown #230

@AArnott

Description

@AArnott

Problem statement

Too much code in Visual Studio runs expensive, async work that slows down IDE shutdown.

Proposed solution

A new analyzer that ensures all JoinableTaskFactory.SwitchToMainThreadAsync calls pass in a CancellationToken (or None or default), with a fix offered to pass in VsShellUtilities.ShutdownToken. The analyzer should only activate when the VsShellUtilities.ShutdownToken symbol is available to the compilation.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions