// ets_tracing: off import type { NonEmptyArrayURI } from "../../../Modules/index.js" import type { URI } from "../../../Prelude/index.js" import * as P from "../../../Prelude/index.js" import * as A from "./operations.js" export const Any = P.instance]>>({ any: () => [{}] }) export const AssociativeBoth = P.instance]>>({ both: A.zip }) export const AssociativeFlatten = P.instance< P.AssociativeFlatten<[URI]> >({ flatten: A.flatten }) export const Covariant = P.instance]>>({ map: A.map }) export const Applicative = P.instance]>>({ ...Any, ...Covariant, ...AssociativeBoth }) export const Monad = P.instance]>>({ ...Any, ...Covariant, ...AssociativeFlatten }) export const ForEach = P.instance]>>({ map: A.map, forEachF: A.forEachF }) export const ForEachWithIndex = P.instance]>>( { map: A.map, forEachWithIndexF: A.forEachWithIndexF } ) export const Extend = P.instance]>>({ extend: A.extend }) export const Reduce = P.instance]>>({ reduce: A.reduce }) export const ReduceWithIndex = P.instance]>>({ reduceWithIndex: A.reduceWithIndex }) export const ReduceRightWithIndex = P.instance< P.ReduceRightWithIndex<[URI]> >({ reduceRightWithIndex: A.reduceRightWithIndex }) export const ReduceRight = P.instance]>>({ reduceRight: A.reduceRight }) export const FoldMap = P.instance]>>({ foldMap: A.foldMap }) export const FoldMapWithIndex = P.instance]>>( { foldMapWithIndex: A.foldMapWithIndex } ) export const Foldable = P.instance]>>({ ...FoldMap, ...Reduce, ...ReduceRight }) export const FoldableWithIndex = P.instance< P.FoldableWithIndex<[URI]> >({ ...FoldMapWithIndex, ...ReduceWithIndex, ...ReduceRightWithIndex })