14 writes to _size
Microsoft.CodeAnalysis.Collections.Package (14)
SegmentedList`1.cs (14)
81_size = segmentedList._size; 99_size = count; 255_size = size + 1; 271_size = size + 1; 327_size += count; 390_size = 0; 396_size = 0; 441list._size = _size; 764list._size = count; 867_size++; 939_size += count; 1121_size = freeIndex; 1134_size--; 1166_size -= count;
89 references to _size
Microsoft.CodeAnalysis.Collections.Package (89)
SegmentedList`1.cs (89)
81_size = segmentedList._size; 129if (value < _size) 179public int Count => _size; 200if ((uint)index >= (uint)_size) 209if ((uint)index >= (uint)_size) 252var size = _size; 268Debug.Assert(_size == _items.Length); 269var size = _size; 307if (_items.Length - _size < count) 309Grow(checked(_size + count)); 314SegmentedArray.Copy(list._items, 0, _items, _size, list.Count); 318SegmentedArray.Copy(array, 0, _items, _size, array.Length); 322var targetIndex = _size; 370if (_size - index < count) 395var size = _size; 417return _size != 0 && IndexOf(item) >= 0; 436var list = new SegmentedList<TOutput>(_size); 437for (var i = 0; i < _size; i++) 441list._size = _size; 462SegmentedArray.Copy(_items, 0, array!, arrayIndex, _size); 476if (_size - index < count) 488SegmentedArray.Copy(_items, 0, array, arrayIndex, _size); 581for (var i = 0; i < _size; i++) 599for (var i = 0; i < _size; i++) 610=> FindIndex(0, _size, match); 613=> FindIndex(startIndex, _size - startIndex, match); 617if ((uint)startIndex > (uint)_size) 622if (count < 0 || startIndex > _size - count) 648for (var i = _size - 1; i >= 0; i--) 659=> FindLastIndex(_size - 1, _size, match); 671if (_size == 0) 682if ((uint)startIndex >= (uint)_size) 714for (var i = 0; i < _size; i++) 757if (_size - index < count) 791=> SegmentedArray.IndexOf(_items, item, 0, _size); 813if (index > _size) 815return SegmentedArray.IndexOf(_items, item, index, _size - index); 829if (index > _size) 832if (count < 0 || index > _size - count) 840if (index > _size) 843if (count < 0 || index > _size - count) 856if ((uint)index > (uint)_size) 860if (_size == _items.Length) 861Grow(_size + 1); 862if (index < _size) 864SegmentedArray.Copy(_items, index, _items, index + 1, _size - index); 897if ((uint)index > (uint)_size) 907if (_items.Length - _size < count) 909Grow(checked(_size + count)); 911if (index < _size) 913SegmentedArray.Copy(_items, index, _items, index + count, _size - index); 922SegmentedArray.Copy(_items, index + count, _items, index * 2, _size - index); 963if (_size == 0) 969return LastIndexOf(item, _size - 1, _size); 984if (index >= _size) 1000if (_size == 0) 1016if (index >= _size) 1031if (_size == 0) 1047if (index >= _size) 1094while (freeIndex < _size && !match(_items[freeIndex])) 1096if (freeIndex >= _size) 1100while (current < _size) 1103while (current < _size && match(_items[current])) 1106if (current < _size) 1117SegmentedArray.Clear(_items, freeIndex, _size - freeIndex); // Clear the elements so that the gc can reclaim the references. 1120var result = _size - freeIndex; 1130if ((uint)index >= (uint)_size) 1135if (index < _size) 1137SegmentedArray.Copy(_items, index + 1, _items, index, _size - index); 1143_items[_size] = default!; 1161if (_size - index < count) 1167if (index < _size) 1169SegmentedArray.Copy(_items, index + count, _items, index, _size - index); 1177SegmentedArray.Clear(_items, _size, count); 1203if (_size - index < count) 1243if (_size - index < count) 1260if (_size > 1) 1262var segment = new SegmentedArraySegment<T>(_items, 0, _size); 1272if (_size == 0) 1277var array = new T[_size]; 1278SegmentedArray.Copy(_items, array, _size); 1294if (_size < threshold) 1296Capacity = _size; 1307for (var i = 0; i < _size; i++) 1340if (_version == localList._version && ((uint)_index < (uint)localList._size)) 1356_index = _list._size + 1; 1367if (_index == 0 || _index == _list._size + 1)