message: retype cross
diff: import * as A from "../../Array"
  import { pipe } from "../../Function"
  +import type { _A, _E, _R } from "../../Utils"
  import { flattenTuples } from "./_internal/flattenTuples"
  import { cross_ } from "./cross"
  import type { Stream } from "./definitions"
  import { map } from "./map"
  -type CrossNFunctionParameters<S extends readonly Stream<any, any, unknown>[]> = {
  - [K in keyof S]: S[K] extends Stream<any, any, infer R> ? R : never
  -}
  -
  -type CrossNFunction<S extends readonly Stream<any, any, unknown>[], O> = (
  - ...f: CrossNFunctionParameters<S>
  -) => O
  -
  /**
  * Composes the specified streams to create a cartesian product of elements
  * with a specified function. Subsequent streams would be run multiple times,
  @@ -20,17 +13,22 @@ type CrossNFunction<S extends readonly Stream<any, any, unknown>[], O> = (
  *
  * See also `Stream#zipN` for the more common point-wise variant.
  */
  -export function crossN<
  - R,
  - E,
  - S1 extends Stream<R, E, unknown>,
  - S2 extends Stream<R, E, unknown>,
  - SN extends readonly Stream<R, E, unknown>[]
  ->(s1: S1, s2: S2, ...streams: SN) {
  - return <O>(f: CrossNFunction<[S1, S2, ...SN], O>): Stream<R, E, O> => {
  +export function crossN<SN extends readonly Stream<any, any, any>[]>(
  + ...[s1, s2, ...streams]: SN & {
  + readonly 0: Stream<any, any, any>
  + readonly 1: Stream<any, any, any>
  + }
  +) {
  + return <O>(
  + f: (
  + ...os: {
  + [k in keyof SN]: _A<SN[k]>
  + }
  + ) => O
  + ): Stream<_R<SN[number]>, _E<SN[number]>, O> => {
  return pipe(
  A.reduce_(streams, cross_(s1, s2), cross_),
  - map((_) => f(...(flattenTuples(_) as CrossNFunctionParameters<[S1, S2, ...SN]>)))
  + map((_) => f(...(flattenTuples(_) as any)))
  )
  }
  }
  