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


当前回答

// Magic. Do not touch.

其他回答

/**---------START-----------**/

  //  IMPLEMENTATION GOES HERE

/**---------END-----------**/

但没有代码;)

我刚刚完成了一个日志框架(使用Trace,为什么没有这样的存在我不知道)。我做了一个继承自TraceListener的方便基类。它覆盖了所有的TraceListener方法,并将它们路由到一个方法中——因此有很多文档注释:

// TODO: Need some codemonkey to doc comment this class.

http://fxr.watson.org/fxr/source/pci/if_rl.c 是好的来源。

# Don use this. Never!
// If I from the future read this I'll back in time and kill myself.