Releases: rescript-lang/rescript-core
Releases · rescript-lang/rescript-core
0.5.0
0.4.0
API changes
- Map, Set, WeakMap, WeakSet: use the types defined in the Js namespace. #143
- Symbol: use the types defined in the Js namespace. #145
- The types RescriptCore.Type.functionandRescriptCore.Type.objectuse the types defined in the Js namespace. #146
- The type RescriptCore.Type.symbolremoved in favor ofRescriptCore.Symbol.t. #146
- Added BigIntsupport forRescriptCore.Classify.t. #146
- Arraymutable & immutable helper name changed to conform to JS' upcoming APIs such as- toSorted- sort->- toSorted,- sortInPlace->- sort
- reverse->- toReversed,- reverseInPlace->- reverse
- splice->- toSpliced,- spliceInPlace->- splice
- shuffle->- toShuffled,- shuffleInPlace->- shuffle
- fillAllInPlace->- fillAll,- fillInPlaceToEnd->- fillToEnd,- fillInPlace->- fill
- added with
 
- Same for TypedArray:- sort->- toSorted,- sortInPlace->- sort
- reverse->- toReversed,- reverseInPlace->- reverse
- fillAllInPlace->- fillAll,- fillInPlaceToEnd->- fillToEnd,- fillInPlace->- fill
 
- And List:- shuffle->- toShuffled
 
- Use floatinstead ofintfor ordering to avoid premature overflow. #149
- Add Orderingmodule. #149
Note 1: These changes should all produce the correct type errors. Though TypedArray's reverse and sort previously mutated and returned the mutated array itself, whereas now they'd be copies. Please be careful refactoring these 2.
Note 2: the newly added helpers, Array.toSorted, Array.toSpliced, Array.toReversed, Array.with, TypedArray.toSorted and TypedArray.toReversed require their respective polyfill, as they're not currently supported by Firefox.
0.3.1
0.3.0
0.2.0
API changes
- Change Map.setto not return self, to indicate that it's mutable. #34
- Change Set.addto not return self, to indicate that it's mutable. #35
- Change Iteratorbindings to have the same shape asAsyncIteratorfor consistency. #34
- Add Iterator.toArraybinding for turning an iterator into an array. #34
- Add Array.atbinding for returning an array item by its index. #48
- Fixed type signatures of Array.fromArrayLikeWithMapandArray.fromIteratorWithMap. #50
- Remove internal async/await helpers that do not need to be exposed in Core.
- Add locale and formatting options to localeDateString,localeStringandlocalTimeStringfunctions #30
- Remove Undefinedmodule.Nullableoroptiondirectly (where appropriate) can be used instead. #59
- Change RegExp.sourceto return astring. Was previously returning abool, which is wrong. #47
- Remove Date.valueOfas it returns the same asDate.getTime. #61
- Change Float.fromStringsignature. Now accepts only string. #54
- Change Float.parseFloatsignature. Now accepts only string. #54
- Add getExn,getUnsafe,getWithDefault,map,mapWithDefaultandflatMaptoNullable. #67
- Add getExn,getUnsafe,getWithDefault,map,mapWithDefaultandflatMaptoNull. #73
- Add make,fromInitializer,findMap,keepSome,reduceRightandreduceRightWithIndex. #49
- Remove reduceReversein favor ofreduceRight. #49
- Fixed type signatures of reduceandreduceWithIndex. #49
- Add panic/Error.panic. #72
- The globally available nullvalue now originates fromNullableand notNull, just like the globally availableundefinedvalue does. #88
- Add Int.rangeandInt.rangeWithOptions, #52
- Remove Array.fromIteratorandArray.fromIteratorWithMap. The same functions exist inIteratorasIterator.fromArrayandIterator.fromArrayWithMapper. #78
- Remove unsafe Array.fromandArray.fromWithMap. #78
Documentation
- Docstrings for MapandIterator. #34
- Docstrings for Global. #39
- Docstrings for Set. #35
- Docstrings for AsyncIterator. #33
- Docstrings for Type. #32
- Docstrings for Int. #37
- Docstrings for Dict. #40
- Docstrings for RegExp. #47
- Docstrings for Date. #61
- Docstrings for Float. #54
- Docstrings for String. #27
- Docstrings from Array. #78