Your code is perfect as is. Small private functions are really helpful so keep doing it. We don't plan to change GenStage. :)
*José Valim* www.plataformatec.com.br Skype: jv.ptec Founder and Director of R&D On Wed, Oct 26, 2016 at 5:03 AM, <[email protected]> wrote: > While I understand the desire to make a stream out of multiple GenStages, > I find myself writing this snippet of code frequently … > > defp gen_stage_to_stream(pid) when is_pid(pid) do > GenStage.stream([pid]) > end > > … so I can then use the stream in a pipe chain. > > This seems a bit cumbersome. Any hope for a version of GenStage.stream > that accepts a single pid outside of a list? > > I'm open to writing a PR if the team is amenable to this. > > -Eric > > -- > You received this message because you are subscribed to the Google Groups > "elixir-lang-core" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/elixir-lang-core/899f7862-b5dd-445e-9bff- > 265fb0587511%40googlegroups.com > <https://groups.google.com/d/msgid/elixir-lang-core/899f7862-b5dd-445e-9bff-265fb0587511%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "elixir-lang-core" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/elixir-lang-core/CAGnRm4%2BmvjT60cZJSH8Re09H3HCFi1%2BHqNWO%3DGRpATfntTsQ%2BA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
