2 ms·
> It's almost a mindset shift as well, like you're requesting the object to do something and don't care how. I definitely see what you mean, a lot of FP encour
by ravi-delia 4y ago
> It's almost a mindset shift as well, like you're requesting the object to do something and don't care how.
I definitely see what you mean, a lot of FP encourages very general abstractions rather than something domain specific. That being said, I think Elixir has a pretty good handle on using functions as sort of black-box interfaces you can change later. Not sure if that's a language thing or a culture thing though.
> Yeah, Dlang has that.
Ooo, that's really nice. Super simple but a definite improvement to readability. Reminds me of |> in Elixir (or ~> in Clojure), particularly the chaining part. It clicks differently though, and definitely makes things readable for many programmers. Now that I'm writing this out, doesn't Rust have something like this? Like functions strapped right to a struct?