/** * Zips this chunk with the specified chunk to produce a new chunk with * pairs of elements from each chunk, filling in missing values from the * shorter chunk with `None`. The returned chunk will have the length of the * longer chunk. * * @tsplus static Chunk.Aspects zipAll * @tsplus pipeable Chunk zipAll */ export function zipAll(that: Chunk) { return (self: Chunk): Chunk, Maybe]> => { return self.zipAllWith( that, (a, b) => [Maybe.some(a), Maybe.some(b)], (a) => [Maybe.some(a), Maybe.none], (b) => [Maybe.none, Maybe.some(b)] ) } }