4 ms·
Wow. I think I'm a decent programmer, but that is some hardcore shit right there. Some of those syntax constructs are really hard to wrap my head around. In a
by pestaa 12y ago
Wow. I think I'm a decent programmer, but that is some hardcore shit right there.
Some of those syntax constructs are really hard to wrap my head around. In a lot of cases `x | f` is more readable than `f(x)` (especially when you want to chain several functions), but there's no way I can remember how to extend the language this way unless I'm a full-time C++ programmer. I don't feel the same in Haskell, for example.
Also, function composition should be similar to this, anyone can shed some light how it would be implemented? (I mean `x | f . g` would look awesome.)
- pbsd 12y agoYou can't overload the `.` operator. However, something like this would work: `x | (f , g)`.
- deleted 12y ago[deleted]