10public readonly
struct TaskAwaiter : ICriticalNotifyCompletion, INotifyCompletion, ITaskAwaiter
40 if (
task.IsWaitNotificationEnabledOrNotRanToCompletion)
49 if (!
task.IsCompleted)
53 task.NotifyDebuggerOfWaitCompletionIfNecessary();
54 if (!
task.IsCompletedSuccessfully)
66 task.GetCancellationExceptionDispatchInfo()?.Throw();
123 Task.RemoveFromActiveTasks(innerTask);
127 bool flag =
log2.IsEnabled();
static void SetCurrentThreadActivityId(Guid activityId)
static Task TryGetContinuationTask(Action continuation)
static Action CreateContinuationWrapper(Action continuation, Action< Action, Task > invokeAction, Task innerTask)
static TaskScheduler Default
static bool s_asyncDebuggingEnabled
static ? Task InternalCurrent
static bool AddToActiveTasks(Task task)
static readonly TplEventSource Log
static Guid CreateGuidForTaskID(int taskID)
void OnCompleted(Action continuation)
static void ThrowForNonSuccess(Task task)
static Action OutputWaitEtwEvents(Task task, Action continuation)
TaskAwaiter(Task< TResult > task)
readonly Task< TResult > m_task
static void HandleNonSuccessAndDebuggerNotification(Task task)
static void ValidateEnd(Task task)
static void OnCompletedInternal(Task task, Action continuation, bool continueOnCapturedContext, bool flowExecutionContext)
void UnsafeOnCompleted(Action continuation)
static void UnsafeOnCompletedInternal(Task task, IAsyncStateMachineBox stateMachineBox, bool continueOnCapturedContext)