METHOD
ValueTask<T>.AsTask
Converts an awaitable value to a Task; consume the resulting task instead of reusing the original value.
Formal Syntax & Structure
csharp syntaxcsharp
valueTask.AsTask()Working Example
Example Snippetcsharp
// Documentary fragment; see lesson for context and imports.Task<int> task = pending.AsTask();