3 ms·
"Why don’t we gate the code with a flag instead of deleting it?" These are all terrible suggestions. Source control systems make it easy to reverse changes, whe
by wouldbecouldbe 2y ago
"Why don’t we gate the code with a flag instead of deleting it?" These are all terrible suggestions. Source control systems make it easy to reverse changes, whereas hundreds of lines of commented code create distractions and confusion."
In most cases to delete code would be a good idea, but to say that source control systems make reverting easier. After a few months most developers will have forgot about those lines and at times uncommenting code & explaining it explicitly might be a better way to preserve knowledge then to rely on digging through GIT.
- lloydatkinson 2y agoFirst time I’m hearing that feature flags and commented out code are the same thing.
- wouldbecouldbe 2y agoI've seen it be a company culture thing where every discussion was resolved with we'll put it behind a config/flag. It's an easy way to avoid hard choices. It's probably something like that the author refers to.
- wiseowise 2y agoNothing like supporting dead code forever just because you might need it some day.