10 references to Cancellation
Microsoft.CodeAnalysis.Workspaces (10)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\RoslynParallel.NetFramework.cs (10)
135while (!state.Cancellation.IsCancellationRequested) 142if (state.Cancellation.IsCancellationRequested || // check now that the lock has been acquired 167await state.LoopBody(element, state.Cancellation.Token); 300while (!state.Cancellation.IsCancellationRequested) 307if (state.Cancellation.IsCancellationRequested || // check now that the lock has been acquired 332await state.LoopBody(element, state.Cancellation.Token); 441_registration = cancellationToken.Register(static o => ((ForEachAsyncState<TSource>)o!).Cancellation.Cancel(), this); 517Cancellation.Cancel(); 544Debug.Assert(!Cancellation.IsCancellationRequested); 622Enumerator = source.GetAsyncEnumerator(Cancellation.Token) ?? throw new InvalidOperationException();