Skip to content

[Suggestion + Implementation] Add combine operator and tests#12

Open
Daniel1of1 wants to merge 1 commit intoRuiAAPeres:masterfrom
Daniel1of1:feature/add-combine-operator
Open

[Suggestion + Implementation] Add combine operator and tests#12
Daniel1of1 wants to merge 1 commit intoRuiAAPeres:masterfrom
Daniel1of1:feature/add-combine-operator

Conversation

@Daniel1of1
Copy link

Add a function of type:

func combine<A,B>(_ ra: Receiver<A>, _ rb: Receiver<B>) -> Receiver<(A,B)> 

Discussion points:

  • Whether it is necessary 😊
  • should it be a free function or method on a receiver (or both) i.e
let r3 = combine(r1,r2)
//vs
let r3 = r1.combine(r2)
  • Code styling, this is a first pass at an implementation.
  • Waiting semantics, whether we give values of (A?,B?) or similar when one side has not received a value yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant