News for hackers. Stuff that matters.
Re:Don't DRY Your Code Prematurely by mmcnl on Thursday May 30, 2024 @03:58PM (#40527941)
Premature DIY can lead to the wrong abstractions. Sometimes code looks similar but actually isn't.
Re:Don't DRY Your Code Prematurely by samtho on Thursday May 30, 2024 @04:18PM (#40528124)
At my first big corporate jobs, I got to work on a codebase that was nothing but premature DRY’d code, but I didn’t know it at the time. As someone who was self taught, and suffered from imposter syndrome as many of us do/did in that situation, I thought I was missing something huge until I was talking to a senior developer and these strange design decisions came up, to which he said something like

> Yeah, that was written by <ex-engineer> and he couldn't abstract his way out of a paper bag

I guess the real lessons were the crappy decisions that someone else made along the way.