- Fix package files bug
- Switch to uncurried V11 compiler
- Use Core library
Move lazy sequences to a separate repository. https://github.com/jmagaram/rescript-seq
- Fixed
Seq.filterMapdidn't work with nested optionsSeq.tailwas not completely lazySeq.dropwas not completely lazySeq.findMapdidn't work with nested optionsSeq.replicateandSeq.replicateWithargument order was not data-first
- Add
Seq.reduceUntilto short-circuit a reduce operationSeq.reduceWhileto short-circuit a reduce operationSeq.splitto reduce adjacent itemsSeq.sumBy(likeSeq.reducebut no initial parameter)Seq.prefixSum(likescanbut does not take an initial parameter)Seq.toListSeq.tailsSeq.appendas synonym forconcatSeq.dropLastSeq.findLastSeq.findMapLastSeq.pairAheadandSeq.pairBehindSeq.neighborsNonEmptyArray.of1,of2,of3andofMany, all zero-cost bindings toArray.of.- In the test framework, enable displaying detailed messages when a test fails. Provide
Test.fromResultandTest.fromPredicate. AlsoexpectThrowandexpectsNotThrow. The expectation text is optional.
- Rename
repeattoreplicate; more like other Seq librariesInvalidArgumentexception notArgumentOfOfRange(spelled wrong)Seq.takeAtMosttoSeq.takeSeq.everynotSeq.everyOrEmpty; less cumbersome and more like arraySeq.everyOknotSeq.allSome(usingeverynotforAll)Seq.everySomenotSeq.allSome(usingeverynotforAll)Seq.joinlikeArray.joinrather thanSeq.joinString. Also require a separator character.Seq.headTailtoSeq.uncons; less cumbersome and used in other libraries.Seq.oncenotSeq.singleton; like Rust. Also provideSeq.onceWithArray.exactlyOnenotArray.exactlyOneValuelikeSeq.exactlyOneArray.of1notArray.fromOneValue
- Remove
Seq.windowAheadandSeq.windowBehind; tricky code here. It worked but not sure it is useful enough.windowAheadwould hang if window size was enormous; fixed that before removing it.Seq.findMapiSeq.fromOption; not sure this will get usedArray.fromSeed; use Seq module insteadArray.pairs; use Seq module insteadArray.filterSomeWith; use Seq module insteadSeq.characters; many ways to split a string and with Core it will feel better since you can doString.splitnotJs.String2.split.Seq.startWithandSeq.endWith; useconcatandprependwithSeq.once.Seq.scani; just callindexedbeforehand if index is needed. The mapping within scan removes the index if it isn't desired, unlikefilteri.Seq.reducei; just callindexedbeforehand if index is needed. The mapping within reduce removes the index if it isn't desired, unlikefilteri.
- Other
- Cleanup lots of code
- Fix bug in
Seq.takewhere generator function was called 1 too many times; not lazy enough Seq.combinationsSeq.permutations
- Fix bug in
allPairswhere sequences are not cached. Seq.reverseSeq.sortBySeq.delay
- Add
Seqmodule
Trampolinemodule to eliminate recursion in functionsOption.map5- Lazy sequences in
Seqmodule; will split into separate repository
- Make
Task.tnot abstract Option.map2,Option.map3,Option.map4and test cleanupOption.flattenArray.filterSomeandArray.filterSomeWith- For untagged unions
Pattern.MakeOption- Turn any pattern into at | undefinedPattern.MakeNullable- Turn any pattern into at | undefined | nullPattern.MakeNull- Turn any pattern into at | nullPattern.MakeTuple2andPattern.MakeTuple3
- Option to only show test failures
- Use the built-in
unknowntype - Move
Patternto a top-level module, not inside theUnionmodule. - Lazy parsing in unions; only do enough until find a match
- Move tests into separate folder and not included in package
- Only includes files needed in package
- Move
TaskResultinto a submodule ofTaskfor usability
- Switch to
commonjsmodule format; supposedly this works better for Rescript libraries - Examples of using rescript-struct for unions, and compared to using functors in this package.
- Add
TaskResult.mapBoth - Add
Task.spy - Fix genType bug with
TaskResult.t
- Rename
matchtomatchABCso if a convenience function is written to wrap theonA,onB, etc. it can use the friendliermatchword. - More tests to make sure they work and demonstrate how to use them in practice. Include examples with convenience functions so you don't have to remember or pattern match on
A,B, andC. - Add convenience functions to pattern match on a single case, like
toAandtoB. - Fix bug in basic int, string, float, etc. patterns that made them unusable because the types were abstract.
- Fix bug where matching input could be anything but should have been just the union type.
- Fix bug in
Unknown.isNullOrUndefined; only checked for undefined