Skip to content

Commit 4a66e46

Browse files
xperiandriclaude
andcommitted
fixup! docs: IndexedList and IIndexedList in the changelog and the collection table
The changelog says that a function which takes a sequence rejects a default flat list given as a sequence with `ArgumentNullException` that names the parameter (`IndexedList`, `IIndexedList`, `IndexedListBuilder` and the `indexedList { }` expression), and that the 1.0.0 `ofSeq`, `concat` and `except` threw `InvalidOperationException` for it, and returned for an empty list in `except`. Both statements were checked by running the functions of the published 1.0.0 assembly and of this branch. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
1 parent d0bc299 commit 4a66e46

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

‎CHANGELOG.md‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3838
that take a range check it before they call the member: the members accept a range whose end overflows `Int32.MaxValue`,
3939
`BinarySearch` accepts a range beyond the end, and `LastIndexOf` and `FindLastIndex` accept a last element at or after
4040
the end and answer with the index of another element.
41+
A function that takes a sequence throws `ArgumentNullException` that names the parameter for a `null` sequence and for a
42+
default `FlatList` given as a sequence, which the members would reject with `InvalidOperationException` while they
43+
enumerate it; the `IIndexedList` and `IndexedListBuilder` modules and the `indexedList { }` expression do the same.
4144
* `sortRange`, `sortRangeWith` and `sortRangeWithComparer` are stable, as the other sorts of `IndexedList` are, and do not
4245
wrap the unstable `ImmutableList<'T>.Sort(index, count, comparer)`.
4346
* The `IIndexedList` module has the functions of `IndexedList` for `IImmutableList<'T>`, without the creation and builder
@@ -86,7 +89,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
8689
length and `ArgumentException` for a negative count, and `skip` and `truncate` return the list and an empty list for a
8790
negative count, where all four threw `ArgumentOutOfRangeException`. `forall2` throws `ArgumentException` for lists of
8891
different lengths when every pair of the shorter list satisfies the predicate, where it returned `true`. `contains` and
89-
`ofBuilder` throw `ArgumentNullException` for a `null` input, where they threw `NullReferenceException`.
92+
`ofBuilder` throw `ArgumentNullException` for a `null` input, where they threw `NullReferenceException`. A default
93+
`FlatList` given as a sequence to `ofSeq`, `concat` and `except` throws `ArgumentNullException`, where it threw
94+
`InvalidOperationException` (`except` of an empty list returned).
9095
* `IndexedList.skipWhile` and `takeWhile` do what their names say, as the functions of `List` do. In 1.0.0, `skipWhile`
9196
returned the elements before the first one that fails the predicate, and `takeWhile` returned the elements from it on.
9297
* `IndexedList.except` removes every element equal to an excluded item and the duplicates of the other elements, as

0 commit comments

Comments
 (0)