Found an obscure bug in a Perl program that I started over 20 years ago. (I have made changes off and on since then.) Decided to rewrite it. Found even more bugs. (A few of the WTF variety.) Sometimes a rewrite is a useful and needed thing.