dotnet / dotnet/dotnet-api-docs
Improve discoverability of effect of a suspended system on delay
- Dominant language
- C#
- Stars
- 949
- Forks
- 1.7k
- Avg merge
- 3d 27m
- Merged PRs (30d)
- 49
Description
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.
Contributor guide
Assessment
This issue has not been assessed yet.