你遇到过的源代码中最好的注释是什么?


当前回答

我在谷歌代码搜索上找到的

    // Constructs a tuple with 2 elements (fucking idiot, use std::pair instead!)
    template <typename T0,typename T1>
    inline tuple <T0,T1> make_tuple (const T0& t0,
            const T1& t1) {
            tuple <T0,T1> t;
            t.get<0>() = t0;
            t.get<1>() = t1;
            return t;
    }

其他回答

刚刚在一些Actionscript中发现了这个,我必须更新…

/*
* spaghetty code in this module.
* hardcoded variables for load paths for the content window.
* Needs (vast) improvement.
*/

..大:(

catch (Domain.ConcurrencyException)
{
    // somebody changed it between the time we loaded it and now.
    // weird, huh?
}
//todo: never to be implemented
public GetRandomNumber()
{
    // Chosen by a fairly rolen dice
    return 12;
}
DataRow[] foundrows = FilterCalendarEntriesBecauseDotNETIsFuckedUp(tbtemp,CalDate);

不是注释,而是一个有趣的函数名