3 ms·
I believe that function composition is the heart of the matter. Side effects and immutability are just the consequences of trying to create a primitive that can
by crimsonalucard 7y ago
I believe that function composition is the heart of the matter. Side effects and immutability are just the consequences of trying to create a primitive that can be used under function composition.
In another post I illustrate exactly why I believe that it IS NOT necessarily abstract and in fact fundamental to FP: https://news.ycombinator.com/item?id=22292105 https://news.ycombinator.com/item?id=22292105
- yodsanklai 7y ago> Side effects and immutability are just the consequences of trying to create a primitive that can be used under function composition I think I see what you mean, but it sounds like you see function composition as the end, where I see it as a mean. To me, being side-effect free is the end because it helps me doing local reasoning which ultimately makes programs easier to reason about. That being said, I understand it may be easier to characterize formally FP using function composition.