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


当前回答

// set break point here - you'll never reach it

其他回答

在PeopleSoft Financials PeopleCode的早期版本中:

/* I don't know how you can ever get here so I'll have to fix it later */

不是一个评论,而是一个goto标签

ICantBelieveImUsingAGoto:
/// <summary>
/// The possible outcomes of an update operation (save or delete)
/// </summary>
public enum UpdateResult
{

    /// <summary>
    /// Updated successfully
    /// </summary>
    Success = 0,

    /// <summary>
    /// Updated successfully
    /// </summary>
    Failed = 1
}
-- Change Log:  Not needed. The code is perfect 'cause I wrote it.
-- If you change it, it will break.

我正在检查一些代码注释,以检查它们是否有意义,并看到上面的一行。

一个可怕的解码补丁(意大利语翻译):

/**
*@return the value 
*@param key: the id of the list of instruments
*@PS this function is a violation of all the laws of the 
*software engineering, 
*commons sense, highway code 
*and ONU decision about the coding.
That sh*t...
*/