▲ | kentonv 3 days ago | ||||||||||||||||
Eh, I think composed function calls have legitimately won _because_ they compose well and are easy to understand, not just because we haven't tried other things. | |||||||||||||||||
▲ | mpweiher 2 days ago | parent [-] | ||||||||||||||||
1. The WWW would like a quick word with you regarding function calls having won. 2. You are making an invalid assumption, which is that we only get to have one tool in our toolbox, and therefore one tool has to "win". Even if function calls were the best tool, they would still not always be the right one. With the benefit of hindsight, it’s clear that these properties of structured programs, although helpful, do not go to the heart of the matter. The most important difference between structured and unstructured programs is that structured programs are designed in a modular way. Modular design brings with it great productivity improvements. First of all, small modules can be coded quickly and easily. Second, general-purpose modules can be reused, leading to faster development of subsequent programs. Third, the modules of a program can be tested independently, helping to reduce the time spent debugging. However, there is a very important point that is often missed. When writing a modular program to solve a problem, one first divides the problem into subproblems, then solves the subproblems, and finally combines the solutions. The ways in which one can divide up the original problem depend directly on the ways in which one can glue solutions together. Therefore, to increase one’s ability to modularize a problem conceptually, one must provide new kinds of glue in the programming language. -- John Hughes, Why Functional Programming Matters https://www.cse.chalmers.se/~rjmh/Papers/whyfp.pdf via https://blog.metaobject.com/2019/02/why-architecture-oriente... 3. Procedure calls are not particularly composable See CORBA vs. REST. | |||||||||||||||||
|