News for hackers. Stuff that matters.
Re:“What if it changes?” by watwut on Monday May 23, 2022 @02:29AM (#31475901)
Imo, the correct rule is "copy if it is more likely to be modified separately" and "create one method if it likely has to change at the same time".
Re:“What if it changes?” by ansmithz42 on Monday May 23, 2022 @05:15AM (#31476791)
Excellent advice! I wish more programmers paid attention to this than just the 2-3 rules. The 2-3 rule tends to create unintentional tight coupling between things that becomes an iron bar that is even more evil to rectify.