For a Good Time

At work I am currently maintaining/adding features to a rather large piece of software. It takes over two hours just to build (but this is mostly because C++ takes a long time to compile, being the ugly mess C++ is). I wondered if there would be any, let's say "interesting", comments in there. With all that code there had to be something! I ran this to find out,

find . -name "*.[chCH]" -exec grep \
        'damn\|fuck\|shit\|kludge\|dragon\|idiot\|stupid\|hell' \
        {} -Hi \;

And I found maybe a hundred matches. A couple of us got some good laughs for awhile reading some very creative comments and, in a few cases, strings for debugging log output. If you want some code to run this on yourself this 2.4.1 release of Pidgin works fairly well. This is my favorite comment, which is followed by a piece of code handling just what it is talking about,

/* holy crap. who the fuck would transfer gigabytes through AIM?! */

For an easier way to search a whole lot of code, someone has already compiled some interesting Google Code Search searches that have interesting results. My favorite is probably this one.

Have fun!

blog comments powered by Disqus

null program

Chris Wellons