34 ms·
That looks interesting but imo the syntax is too terse. Coming from Rust and Golang I very much appreciate the use of sigils and syntax sugar in moderation but
by c0balt 2y ago
That looks interesting but imo the syntax is too terse. Coming from Rust and Golang I very much appreciate the use of sigils and syntax sugar in moderation but especially the pipe operators look like they could lead to hard to debug code very easily.
- botanical76 2y agoYou get used to it. It's really nice in Elixir. I'm not a fan of the fat pipe though.
- paxcoder 2y ago[dead]
- legacynl 2y agoThe pipe operator just flips the order of execution. In my experience this doesn't really impact debugging at all. without the pipe operator you would write ` fun1(fun2(fun3(fun4(fun5(x, y), z, w), u), v)) ` The order of operations in this line is actually from right to left. Also it's not immediately obvious to which function the u parameter belongs to. With the pipe operate you would write it in the order that the functions are actually called and you have the arguments in the same location as the function they belong to. So this would be written something like ` fun5(x, y) |> fun4(z, w) |> fun3(u) |> fun2(v) |> fun1() `