Re:Code duplication is far cheaper than the wrong abstraction
by mytydev on Sunday June 21, 2026 @01:27PM
(#48620769)
It sounds to me like you are describing a good abstraction. This article does not claim that code duplication is better than any abstraction. It claims that code duplication is better than the wrong abstraction. I'm sure this author would agree that a good abstraction is better than code duplication.
[ Parent
| on HN ]
Re:Code duplication is far cheaper than the wrong abstraction
by dofm on Sunday June 21, 2026 @01:31PM
(#48620809)
I'm afraid this comment reads in a rather gnomic way.
Of course it's a truism if you just say any abstraction that works is a good abstraction.
That is not what I am saying at all. Bullshit abstractions at least let you control the problem. Duplication doesn't.
Re:Code duplication is far cheaper than the wrong abstraction
by vlunkr on Sunday June 21, 2026 @01:38PM
(#48620872)
But it’s never going to be 1:1 duplication is it? Sometimes it’s better to copy code as a template for something new, rather than try to immediately force a new abstraction.
I agree with you that it’s a truism, but it’s useful advice for people who have a habit of trying too hard to DRY their code. IIRC the author comes from the Ruby world, where DRY was a big thing, and this talk was part of the pendulum swinging back away from this DRY obsession that sometimes just resulted in convoluted code.