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


当前回答

[onload_1;block=begin;when 1=0]

Some of the techinques in this template are rather obscure, just trust me, they need to be there.
OTOH a better sollution would be to create a few seperate templates and pick one in the php-script...

[onload_1;block=end]

其他回答

Get This hack!

在一行汇编代码中,在几页未注释的代码之后。

// if the resultMap size is less than or equal to zero
// then the product is added
if (resultMap.size() <= 0)

当被问及什么是“最好的评论”时,我们的回答都是我们能找到的最糟糕的评论,这充分说明了我们的职业……

我告诉学员至少做一些异常处理。这是我在每一个db调用....返回

Catch (Exception e) {
    //eat it
}

从C #

#region Hack - Shield Eyes Before Expanding

/// <summary>
/// A single uint with all of the bits set to represent the different tracing
/// </summary>
/// <remarks>
/// Ugly I know, so if you can think of a better way, feel free to rewrite.
/// </remarks>
[Browsable(false)]
public uint TraceBitfield
{
    // Snip
}

#endregion