9 writes to _count
System.Collections.Immutable (9)
System\Collections\Immutable\ImmutableArray_1.Builder.cs (9)
37_count = 0; 124_count = value; 211_count = 0; 234_count = 0; 262_count++; 292_count += count; 318_count += items.Length; 330_count = newCount; 348_count += count;
27 references to _count
System.Collections.Immutable (27)
System\Collections\Immutable\ImmutableArray_1.Builder.cs (27)
57if (value < _count) 67if (_count > 0) 69Array.Copy(_elements, temp, _count); 93return _count; 99if (value < _count) 106if (_count - value > 64) 108Array.Clear(_elements, value, _count - value); 118else if (value > _count) 228if (result.Length != _count) 281Array.Copy(_elements, index, _elements, index + count, _count - index); 313Array.Copy(_elements, index, _elements, index + items.Length, _count - index); 327int newCount = _count + 1; 329_elements[_count] = item; 346if (items.TryCopyTo(_elements, _count)) 521int index = this.IndexOf(element, 0, _count, equalityComparer); 545for (int i = 0; i < _count; i++) 583Requires.Range(index >= 0 && index <= _count, nameof(index)); 584Requires.Range(length >= 0 && index <= _count - length, nameof(length)); 591if (index + length < this._count) 623int index = this.IndexOf(item, 0, _count, equalityComparer); 624while (index >= 0 && !indicesToRemove.Add(index) && index + 1 < _count) 654int index = this.IndexOf(oldValue, 0, _count, equalityComparer); 749return this.IndexOf(item, 0, _count, EqualityComparer<T>.Default); 917Array.Reverse<T>(_elements, 0, _count); 948_elements.AsSpan(0, _count).Sort(comparison); 967Array.Sort(_elements, 0, _count, comparer); 1078internal Memory<T> AsMemory() => new(_elements, 0, _count);