Skip to content

Improve discoverability of effect of a suspended system on delay #3850

@breyed

Description

@breyed

The documentation for Task.Delay does not specify its behavior when the system is suspended, nor do its docs link to external docs on the topic. One way or another, it should be easy for a developer to discover what the behavior will be.

I had submitted PR #2354 to specify the suspend behavior directly in the Task.Delay docs, to which @stephentoub suggested a different approach:

I'm fine personally with it being documented, but Task.Delay isn't the place to do it IMO. If we want to document suspension behavior, we should do it on System.Threading.Timer, and then we could say in Task.Delay's docs that it has the same behavior as Timer.

This issue captures the need for a PR of that sort.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Pri3Indicates issues/PRs that are low priorityarea-System.Threading.TasksuntriagedNew issue has not been triaged by the area owner

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions