1 write to _lock
System.Threading.Tasks.Parallel (1)
System\Threading\Tasks\Parallel.ForEachAsync.cs (1)
543_lock = needsLock ? new SemaphoreSlim(initialCount: 1, maxCount: 1) : null;
4 references to _lock
System.Threading.Tasks.Parallel (4)
System\Threading\Tasks\Parallel.ForEachAsync.cs (4)
601Debug.Assert(_lock is not null, "Should only be invoked when _lock is non-null"); 602return _lock.WaitAsync(CancellationToken.None); 608Debug.Assert(_lock is not null, "Should only be invoked when _lock is non-null"); 609_lock.Release();