4 ms·
I confess I've never seen that happen, but I do think excessive abstraction is killing the argument this article is trying to make. When would anyone ever make
by ken 8y ago
I confess I've never seen that happen, but I do think excessive abstraction is killing the argument this article is trying to make.
When would anyone ever make an inc_pair function? Or a hierarchy of 'animals that lay eggs'? I guess these are supposed to be examples of something, but I'm not sure what. I wouldn't even call them "abstraction". They seem like completely hypothetical examples of how to apply programming language features to non-problems in bad ways.
Without knowing what the designer of these programs is trying to model, it's impossible for me to understand what they're trying to accomplish or why they think applying these language features in this way makes sense at all.
Both of these examples sound like they increase the number of lines of code, for no appreciable benefit, and I recall Yegge's old observation that the main issue with any codebase is simply the bulk of it.
- Tarean 8y agoOn the other hand, the lens library in haskell is extremely abstract. Libraries obviously have different tradeoffs but using lens can increase the onboarding cost significantly for new team members. I am mentioning lens because it has a both function: incBoth = both += 1 Which has a fun type signature: incBoth :: (Bitraversal p, MonadState (p a a) m, Num a) => m ()
- tome 8y agoHmm, don't you use it as a monadic action like do ... both += 1
- dllthomas 8y ago> completely hypothetical examples of how to apply programming language features to non-problems in bad ways. If that were Randall Munroe's next book, I'd buy a copy.