3 ms·
> You could end up with tons of small functions, and complex interactions between them (whether they are pure or not) than make for spaghetti logic. I think 'o
by cormacrelf 10y ago
> You could end up with tons of small functions, and complex interactions between them (whether they are pure or not) than make for spaghetti logic.
I think 'one thing well' is pretty much the opposite of this idea. It implies encapsulation and composition, not smushing together. If some functions are pure, there is no such thing as 'complex interactions between them', only simple ones.
On the other hand, it would definitely be weird if Ada were used as a functional programming language.
- yoz-y 10y agoNot all things can be expressed by simple interactions between simple functions. A program doing complex tasks composed of pure functions will be either wide (fewer functions but having many parameters) or tall (long string of functions with few parameters). I do not believe that a simple paradigm shift will help you create arbitrarily complex programs simply. At some point the complexity must be handled.