Hi David,

If you search the mailing list archives, you will see proposals to the pipe
operator are very common. If we had accepted them all, it would have become
a very complex beast.

The pipe operator works because it is simple. So we plan to keep it that
way.

Thank you,



*José Valim*
www.plataformatec.com.br
Skype: jv.ptec
Founder and Director of R&D

On Thu, Aug 17, 2017 at 1:01 PM, <[email protected]> wrote:

> We all love the feeling of writing a nice pipeline, but using anonymous
> functions and captures to deal with :ok tuples can get rather frustrating.
>
> Instead, I'd like the ability to utilise `!>! to tell the Elixir to unwrap
> the tuple for me, only on {:ok, val} - crashing on anything else.
>
> Example:
>
> 1
> |> twice         # 2
> |> ok_tuple      # {:ok, 2}
> !> twice         # 4
>
> defp twice(val), do:val*2
> defp ok_tuple(val), do: {:ok,val}
>
> I have already started an implementation and it seems pretty simple. The
> only question now is: Is this a valuable addition to Elixir?
>
> --
> 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/ms
> gid/elixir-lang-core/1c6103ec-bf2c-4366-984c-bdc5a931191b%
> 40googlegroups.com
> <https://groups.google.com/d/msgid/elixir-lang-core/1c6103ec-bf2c-4366-984c-bdc5a931191b%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/CAGnRm4KzqL32JxPy%3DKT4S4BGsMMuAEZKWXQR8U_Tiq4URDt0Pw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to