18 references to InsertRange
Microsoft.CodeAnalysis (1)
src\Dependencies\Collections\Segmented\ImmutableSegmentedList`1.cs (1)
616=> InsertRange(index, items);
Microsoft.CodeAnalysis.UnitTests (17)
Collections\ImmutableSegmentedListTest.cs (17)
79actual = actual.InsertRange(position, values); 279Assert.Throws<ArgumentOutOfRangeException>("index", () => list.InsertRange(1, new[] { 1 })); 280Assert.Throws<ArgumentOutOfRangeException>("index", () => list.InsertRange(-1, new[] { 1 })); 282list = list.InsertRange(0, new[] { 1, 4, 5 }); 283list = list.InsertRange(1, new[] { 2, 3 }); 284list = list.InsertRange(2, new int[0]); 287Assert.Throws<ArgumentOutOfRangeException>("index", () => list.InsertRange(6, new[] { 1 })); 288Assert.Throws<ArgumentOutOfRangeException>("index", () => list.InsertRange(-1, new[] { 1 })); 296Assert.Throws<ArgumentOutOfRangeException>("index", () => list.InsertRange(1, nonEmptyList)); 297Assert.Throws<ArgumentOutOfRangeException>("index", () => list.InsertRange(-1, nonEmptyList)); 299list = list.InsertRange(0, ImmutableSegmentedList.Create(1, 104, 105)); 300list = list.InsertRange(1, ImmutableSegmentedList.Create(2, 3)); 301list = list.InsertRange(2, ImmutableSegmentedList<int>.Empty); 302list = list.InsertRange(3, ImmutableSegmentedList<int>.Empty.InsertRange(0, Enumerable.Range(4, 100))); 305Assert.Throws<ArgumentOutOfRangeException>("index", () => list.InsertRange(106, nonEmptyList)); 306Assert.Throws<ArgumentOutOfRangeException>("index", () => list.InsertRange(-1, nonEmptyList));