Date: Mon, 09 Aug 2010 18:19:28 +0200 From: Jean-Yves Migeon <jeanyves.mig...@free.fr> Message-ID: <e2568087e60b3c2943d03413cd7e5...@localhost>
I agree with pooka, no code changes to existing code just to make the code look better. | However, I would prefer to have code using roundup/MIN/MAX rather than | rewriting them down. It tends to be harder to read, no matter the | developer's expertise can be. If you're developing new code, or even making changes to existing code for some other reason, then fine - but changing the code just because you can't think of anything else to do, is not useful, however much you would prefer it if the code had been written in a different style. | Does code quality, DRY, or KNF fit in? No. If the code is there, and works as it is supposed to, then leave it alone. If it needs changing for some reason (adding features, removing old stuff that is no longer wanted, fixing bugs, improving performance, ...) then change it as needed. Otherwise, leave it alone. | I hardly see how the thing can go wrong in this /very/ | simple case though: dependency on cdefs, exact semantic match. One obvious example is that it makes it much harder in the future to pullups of fixes to code in this area to earlier NetBSD versions - the diffs show all of this meaningless churn as well as the real change. The same for anyone looking to see why something that used to work no longer does - you might be sure that your changes cannot possibly do any harm, but all someone else sees is a whole bunch of files changed between the version that worked last week, and the new version that doesn't work this week, that they're going to have to filter through to figure out what change actually broke things, even if your change was not responsible (and it probably wouldn't be) you've caused lots of needless unnecessary work. Please don't. kre ps: this has nothing whatever to do with the tool you're using to assist, whether this is done by hand, or automated, makes no real difference.