Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
What is the best comment in source code you have ever encountered? (stackoverflow.com)
2 points by jyothi on Aug 23, 2010 | hide | past | favorite | 3 comments


Some of my favourites:

    // somedev1 -  6/7/02 Adding temporary tracking of Login screen
    // somedev2 -  5/22/07 Temporary my ass


    //When I wrote this, only God and I understood what I was doing
    //Now, God only knows


    Exception up = new Exception("Something is really wrong.");
    throw up;  //ha ha


From Unix, Sixth Edition:

    /*
     * If the new process paused because it was
     * swapped out, set the stack level to the last call
     * to savu(u_ssav).  This means that the return
     * actually returns from the last routine which did
     * the savu.
     *
     * You are not expected to understand this.
     */


My favorite would be a comment in some generated html (no other comments around it

<!-- this are some comments -->

Later it was "fixed"

<!-- these are some comments -->




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: