Seq.unfoldMany
is new and similar toSeq.unfold
but recursively generates a sequence of sequences.
Seq.iterateWhile
generates a sequence until the interation function returnsNone
.
Seq.at
returns the item at a specified zero-based index.
- Ordering callback functions must return a float not an int, like Core
- Use V11 with the default uncurried mode
- Use Core library instead of Js and Belt
- Upgrade to V11 compiler
- Still using curried mode
- Not using @rescript/core yet
- Fixed
Seq.filterMap
didn't work with nested optionsSeq.tail
was not completely lazySeq.drop
was not completely lazySeq.findMap
didn't work with nested optionsSeq.replicate
andSeq.replicateWith
argument order was not data-first
- Add
Seq.append
as synonym forconcat
Seq.dropLast
Seq.findLast
Seq.findMapLast
Seq.neighbors
Seq.onceWith
Seq.pairAhead
Seq.pairBehind
Seq.prefixSum
(likescan
but does not take an initial parameter)Seq.reduceUntil
to short-circuit a reduce operationSeq.reduceWhile
to short-circuit a reduce operationSeq.split
to split adjacent items and then reduce the groupsSeq.sumBy
(likeSeq.reduce
but no initial parameter)Seq.tails
Seq.toList
- Rename
repeat
toreplicate
; more like other Seq librariesInvalidArgument
exception notArgumentOfOfRange
(spelled wrong)Seq.takeAtMost
toSeq.take
Seq.every
notSeq.everyOrEmpty
; less cumbersome and more like arraySeq.everyOk
notSeq.allSome
(usingevery
notforAll
)Seq.everySome
notSeq.allSome
(usingevery
notforAll
)Seq.join
likeArray.join
rather thanSeq.joinString
. Also require a separator character.Seq.uncons
rather thanSeq.headTail
; less cumbersome, more consistentSeq.once
notSeq.singleton
; like RustArray.exactlyOne
notArray.exactlyOneValue
likeSeq.exactlyOne
Array.of1
notArray.fromOneValue
- Remove
Seq.windowAhead
andSeq.windowBehind
; tricky code here. It worked but not sure it is useful enough.windowAhead
would hang if window size was enormous; fixed that before removing it.Seq.findMapi
Seq.fromOption
; not sure this will get usedSeq.characters
; many ways to split a string and with Core it will feel better since you can doString.split
notString.split
.Seq.startWith
andSeq.endWith
; useconcat
andprepend
withSeq.once
.Seq.scani
; just callindexed
beforehand if index is needed.Seq.reducei
; just callindexed
beforehand if index is needed.
- Other
- Cleanup lots of code
- Fix bug in
Seq.take
where generator function was called 1 too many times; not lazy enough Seq.combinations
Seq.permutations
- Fix bug in
allPairs
where sequences are not cached. Seq.reverse
Seq.sortBy
Seq.delay
- Add
Seq
module