import { OperatorFunction } from '../../interfaces'; import { IterableX } from '../../iterable/iterablex'; import { ScanRightIterable } from '../scanright'; export function scanRight( accumulator: (previousValue: R, currentValue: T, currentIndex: number) => R, seed?: never[] ): OperatorFunction; export function scanRight( accumulator: (previousValue: R, currentValue: T, currentIndex: number) => R, seed?: R ): OperatorFunction; export function scanRight( accumulator: (previousValue: R, currentValue: T, currentIndex: number) => R, ...seed: R[] ): OperatorFunction { return function scanRightOperatorFunction(source: Iterable): IterableX { return new ScanRightIterable(source, accumulator, seed); }; }