4 ms·
There is a point there to be made, but it is a strawman nevertheless. Code reuse is infact sometimes and often desirable, and even gasp if it does turn up the l
by lsd5you 16y ago
There is a point there to be made, but it is a strawman nevertheless. Code reuse is infact sometimes and often desirable, and even gasp if it does turn up the level of expertise required to use/work with a particular library/framework. The important thing is to realise that their are alternative approaches and dispassionately understand the compromises involved - a judicious use of judgement.
Calculating factorials (pretending for a moment that it is occasionally worthwhile thing to do) is only ever 2 or 3 lines and it makes no sense to create a flexible implementation, especially if it is also has to be made efficient.
On the otherhand, what about a templating engine? How much string concatanation do you have to do before you can justify using a framework? Now obviously some languages have it built in, e.g. in groovy you can reference variables in scope within strings. This is all very well, and is definitely a nice feature, but ... the abstraction remains more leaky than a dedicated templating engine. In line templates are inextricably linked to the code and this has its disadvantages.
When there are clean conceptual breaks to be made in code it is often desirable to do so. I believe it is for this fundamental reason that lisp has not taken off because although it is very powerful, it discourages the creation/maintenance of library code, but in fact high quality library code is better in many situations than just using powerful language features.