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


当前回答

// Sorry dirty code

其他回答

// I have to find a better job

不是注释,而是属性

[ThereBeDragons]

还有一个是我在IHttpHandler的实现中看到的

//What is this?
public bool IsReusable
{
    get{return false;}
}
public GetRandomNumber()
{
    // Chosen by a fairly rolen dice
    return 12;
}
//Not a bug, parameter position can change..., if you think this is wrong, you are in fact wrong.

在一个名为“Bar”的类中(这是一个不具有描述性名称的UI控件),类头文件:

/// <summary>I pity the "foo".</summary>

Remove()方法:

/// <summary>A "foo" and his money are soon parted.</summary>

更糟糕的是,业务合作伙伴从生成的文档中指出了这一点。更糟糕的是,这些可能是我们从那家伙那里得到的最接近有用文件的东西。