Skip to content

Commit

Permalink
version 2.11.2
Browse files Browse the repository at this point in the history
  • Loading branch information
gcanti committed Sep 13, 2021
1 parent e981a6d commit 82bc860
Show file tree
Hide file tree
Showing 5 changed files with 219 additions and 72 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Expand Up @@ -16,6 +16,11 @@
**Note**: A feature tagged as Experimental is in a
high state of flux, you're at risk of it changing without notice.

# 2.11.2

- **Polish**
- Add/fix pure comments, #1555 (@OliverJAsh)

# 2.11.1

- **Deprecation**
Expand Down
2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "fp-ts",
"version": "2.11.1",
"version": "2.11.2",
"description": "Functional programming in TypeScript",
"main": "lib/index.js",
"module": "es6/index.js",
Expand Down
4 changes: 3 additions & 1 deletion src/Ord.ts
Expand Up @@ -233,7 +233,9 @@ export const Contravariant: Contravariant1<URI> = {
*/
export const trivial: Ord<unknown> = {
equals: constTrue,
compare: /*#__PURE__*/ constant(0)
compare:
/*#__PURE__*/
constant(0)
}

/**
Expand Down
140 changes: 105 additions & 35 deletions src/ReadonlyRecord.ts
Expand Up @@ -1517,9 +1517,15 @@ export const getDifferenceMagma = <A>(): Magma<ReadonlyRecord<string, A>> => ({
*/
export const Foldable: Foldable1<URI> = {
URI,
reduce: /*#__PURE__*/ _reduce(S.Ord),
foldMap: /*#__PURE__*/ _foldMap(S.Ord),
reduceRight: /*#__PURE__*/ _reduceRight(S.Ord)
reduce:
/*#__PURE__*/
_reduce(S.Ord),
foldMap:
/*#__PURE__*/
_foldMap(S.Ord),
reduceRight:
/*#__PURE__*/
_reduceRight(S.Ord)
}

/**
Expand All @@ -1531,12 +1537,24 @@ export const Foldable: Foldable1<URI> = {
*/
export const FoldableWithIndex: FoldableWithIndex1<URI, string> = {
URI,
reduce: /*#__PURE__*/ _reduce(S.Ord),
foldMap: /*#__PURE__*/ _foldMap(S.Ord),
reduceRight: /*#__PURE__*/ _reduceRight(S.Ord),
reduceWithIndex: /*#__PURE__*/ _reduceWithIndex(S.Ord),
foldMapWithIndex: /*#__PURE__*/ _foldMapWithIndex(S.Ord),
reduceRightWithIndex: /*#__PURE__*/ _reduceRightWithIndex(S.Ord)
reduce:
/*#__PURE__*/
_reduce(S.Ord),
foldMap:
/*#__PURE__*/
_foldMap(S.Ord),
reduceRight:
/*#__PURE__*/
_reduceRight(S.Ord),
reduceWithIndex:
/*#__PURE__*/
_reduceWithIndex(S.Ord),
foldMapWithIndex:
/*#__PURE__*/
_foldMapWithIndex(S.Ord),
reduceRightWithIndex:
/*#__PURE__*/
_reduceRightWithIndex(S.Ord)
}

/**
Expand All @@ -1549,10 +1567,18 @@ export const FoldableWithIndex: FoldableWithIndex1<URI, string> = {
export const Traversable: Traversable1<URI> = {
URI,
map: _map,
reduce: /*#__PURE__*/ _reduce(S.Ord),
foldMap: /*#__PURE__*/ _foldMap(S.Ord),
reduceRight: /*#__PURE__*/ _reduceRight(S.Ord),
traverse: /*#__PURE__*/ _traverse(S.Ord),
reduce:
/*#__PURE__*/
_reduce(S.Ord),
foldMap:
/*#__PURE__*/
_foldMap(S.Ord),
reduceRight:
/*#__PURE__*/
_reduceRight(S.Ord),
traverse:
/*#__PURE__*/
_traverse(S.Ord),
sequence
}

Expand All @@ -1567,19 +1593,39 @@ export const TraversableWithIndex: TraversableWithIndex1<URI, string> = {
URI,
map: _map,
mapWithIndex: _mapWithIndex,
reduce: /*#__PURE__*/ _reduce(S.Ord),
foldMap: /*#__PURE__*/ _foldMap(S.Ord),
reduceRight: /*#__PURE__*/ _reduceRight(S.Ord),
reduceWithIndex: /*#__PURE__*/ _reduceWithIndex(S.Ord),
foldMapWithIndex: /*#__PURE__*/ _foldMapWithIndex(S.Ord),
reduceRightWithIndex: /*#__PURE__*/ _reduceRightWithIndex(S.Ord),
traverse: /*#__PURE__*/ _traverse(S.Ord),
reduce:
/*#__PURE__*/
_reduce(S.Ord),
foldMap:
/*#__PURE__*/
_foldMap(S.Ord),
reduceRight:
/*#__PURE__*/
_reduceRight(S.Ord),
reduceWithIndex:
/*#__PURE__*/
_reduceWithIndex(S.Ord),
foldMapWithIndex:
/*#__PURE__*/
_foldMapWithIndex(S.Ord),
reduceRightWithIndex:
/*#__PURE__*/
_reduceRightWithIndex(S.Ord),
traverse:
/*#__PURE__*/
_traverse(S.Ord),
sequence,
traverseWithIndex: /*#__PURE__*/ _traverseWithIndex(S.Ord)
traverseWithIndex:
/*#__PURE__*/
_traverseWithIndex(S.Ord)
}

const _wither = /*#__PURE__*/ witherDefault(Traversable, Compactable)
const _wilt = /*#__PURE__*/ wiltDefault(Traversable, Compactable)
const _wither =
/*#__PURE__*/
witherDefault(Traversable, Compactable)
const _wilt =
/*#__PURE__*/
wiltDefault(Traversable, Compactable)

/**
* Use `getWitherable` instead.
Expand All @@ -1591,10 +1637,18 @@ const _wilt = /*#__PURE__*/ wiltDefault(Traversable, Compactable)
export const Witherable: Witherable1<URI> = {
URI,
map: _map,
reduce: /*#__PURE__*/ _reduce(S.Ord),
foldMap: /*#__PURE__*/ _foldMap(S.Ord),
reduceRight: /*#__PURE__*/ _reduceRight(S.Ord),
traverse: /*#__PURE__*/ _traverse(S.Ord),
reduce:
/*#__PURE__*/
_reduce(S.Ord),
foldMap:
/*#__PURE__*/
_foldMap(S.Ord),
reduceRight:
/*#__PURE__*/
_reduceRight(S.Ord),
traverse:
/*#__PURE__*/
_traverse(S.Ord),
sequence,
compact,
separate,
Expand Down Expand Up @@ -1640,10 +1694,18 @@ export const readonlyRecord: FunctorWithIndex1<URI, string> &
Witherable1<URI> = {
URI,
map: _map,
reduce: /*#__PURE__*/ _reduce(S.Ord),
foldMap: /*#__PURE__*/ _foldMap(S.Ord),
reduceRight: /*#__PURE__*/ _reduceRight(S.Ord),
traverse: /*#__PURE__*/ _traverse(S.Ord),
reduce:
/*#__PURE__*/
_reduce(S.Ord),
foldMap:
/*#__PURE__*/
_foldMap(S.Ord),
reduceRight:
/*#__PURE__*/
_reduceRight(S.Ord),
traverse:
/*#__PURE__*/
_traverse(S.Ord),
sequence,
compact,
separate,
Expand All @@ -1652,14 +1714,22 @@ export const readonlyRecord: FunctorWithIndex1<URI, string> &
partition: _partition,
partitionMap: _partitionMap,
mapWithIndex: _mapWithIndex,
reduceWithIndex: /*#__PURE__*/ _reduceWithIndex(S.Ord),
foldMapWithIndex: /*#__PURE__*/ _foldMapWithIndex(S.Ord),
reduceRightWithIndex: /*#__PURE__*/ _reduceRightWithIndex(S.Ord),
reduceWithIndex:
/*#__PURE__*/
_reduceWithIndex(S.Ord),
foldMapWithIndex:
/*#__PURE__*/
_foldMapWithIndex(S.Ord),
reduceRightWithIndex:
/*#__PURE__*/
_reduceRightWithIndex(S.Ord),
filterMapWithIndex: _filterMapWithIndex,
filterWithIndex: _filterWithIndex,
partitionMapWithIndex: _partitionMapWithIndex,
partitionWithIndex: _partitionWithIndex,
traverseWithIndex: /*#__PURE__*/ _traverseWithIndex(S.Ord),
traverseWithIndex:
/*#__PURE__*/
_traverseWithIndex(S.Ord),
wither: _wither,
wilt: _wilt
}

0 comments on commit 82bc860

Please sign in to comment.