-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Is your feature request related to a problem? Please describe.
It can be tedious to declare a new structure every time we need to transfer various related data between the conveyor elements.
Describe the solution you'd like
Now we need to declare a new structure to communicate between pipes, I suggest next:
type msgOneToTwo = pipe.Tuple2[string, int]
type msgTwoToThree = pipe.Tuple2[int, string]
msg1 := make(chan msgOneToTwo, 2>>8)
msg2 := pipe.Map(..., func(msg msgOneToTwo) msgTwoToThree {
return pipe.T2(msg.B, msg.A)
}, msg1)
... := pipe.Map(..., msg2)Describe alternatives you've considered
I found a convenient solution to this problem using the samber/lo. It would be good to introduce tuples into the current module.
Additional context
none
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request