▲ 712 ▼ I am God's greatest programmer (lemmy.world) submitted 2 years ago by bigboismith@lemmy.world to c/programmer_humor@programming.dev 46 comments fedilink hide all child comments
[+] BaardFigur@lemmy.world 13 points 2 years ago* (1 child) [deleted] permalink fedilink source parent hideshow 2 child comments replies: [–] CodeMonkey@programming.dev 10 points 2 years ago (1 child) If you are creating an alternative implementation and leaving the old one in place, you are not fixing a problem, you are just creating a new one (and a third one because you have duplication of logic). Either refactor the old function so that it transparently calls the new logic or delete the old function and replace all the existing usage with usage of the new one. It does not need to happen as a single commit. You can check in the new function, tell everyone to use it, and clean up usage of the old one. If anyone tries to use the old implementation, call them out in a code review. If removing or replacing the old implementation is not possible, at least mark it as deprecated so that anyone using it gets a warning. permalink fedilink source parent hideshow 2 child comments replies: [+] BaardFigur@lemmy.world 5 points 2 years ago* (last edited 2 years ago) (1 child) [deleted] permalink fedilink source parent hideshow 2 child comments replies: [–] magic_lobster_party@kbin.social 5 points 2 years ago I’m sure that ring buffer started out as a “temporary solution”. permalink fedilink source parent
[–] CodeMonkey@programming.dev 10 points 2 years ago (1 child) If you are creating an alternative implementation and leaving the old one in place, you are not fixing a problem, you are just creating a new one (and a third one because you have duplication of logic). Either refactor the old function so that it transparently calls the new logic or delete the old function and replace all the existing usage with usage of the new one. It does not need to happen as a single commit. You can check in the new function, tell everyone to use it, and clean up usage of the old one. If anyone tries to use the old implementation, call them out in a code review. If removing or replacing the old implementation is not possible, at least mark it as deprecated so that anyone using it gets a warning. permalink fedilink source parent hideshow 2 child comments replies: [+] BaardFigur@lemmy.world 5 points 2 years ago* (last edited 2 years ago) (1 child) [deleted] permalink fedilink source parent hideshow 2 child comments replies: [–] magic_lobster_party@kbin.social 5 points 2 years ago I’m sure that ring buffer started out as a “temporary solution”. permalink fedilink source parent
[+] BaardFigur@lemmy.world 5 points 2 years ago* (last edited 2 years ago) (1 child) [deleted] permalink fedilink source parent hideshow 2 child comments replies: [–] magic_lobster_party@kbin.social 5 points 2 years ago I’m sure that ring buffer started out as a “temporary solution”. permalink fedilink source parent
[–] magic_lobster_party@kbin.social 5 points 2 years ago I’m sure that ring buffer started out as a “temporary solution”. permalink fedilink source parent