Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add special handling for Iterables passed to zip operators #397

Closed
benlesh opened this issue Sep 24, 2015 · 0 comments · Fixed by #399
Closed

Add special handling for Iterables passed to zip operators #397

benlesh opened this issue Sep 24, 2015 · 0 comments · Fixed by #399

Comments

@benlesh
Copy link
Member

benlesh commented Sep 24, 2015

So the idea is this (I'll use Observable.zip as an example):

Assume:

Observable.zip(observable1, observable2, iterable);

The iterable will be treated differently, in that instead of being converted to an Observable and firehosing out nexts, it will get an iterator and next() once, waiting for the other Observables to emit.. as soon as the zip emits, the iterator will next() once more, and so on.

Each time the iterator.next() is called, the IteratorResult will be examined to see if it's done, if it's done, it will flag itself as no longer active and the Observable will end

@lock lock bot locked as resolved and limited conversation to collaborators Jun 7, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant