I was looking recently into transforming a stream in a one-to-one way that requires maintaining an additional accumulator during the transition. That's an obvious use case for map_reduce with Enum, but with Stream we lack such a function. We have transform/3 that is somewhat equivalent to Enum.flat_map_reduce, that we could use here, but I think I'd prefer something simpler. I'm not 100% sure about the name, though.
Michał.
--
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 elixir-lang-core+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elixir-lang-core/2e5eb853-9fd8-4410-a82c-18da0297d4b5%40Spark.
For more options, visit https://groups.google.com/d/optout.
To unsubscribe from this group and stop receiving emails from it, send an email to elixir-lang-co...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elixir-lang-core/CAGnRm4JWK9JRNarJuo4ZPpB05-n%2B6s5U3k0SHt5rxWbEzbLGKQ%40mail.gmail.com.