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


当前回答

public function get state( /* of Palestine back */ ):Boolean

其他回答

long time; /* just seems that way */

//下面的代码需要被注释掉

// for 8 or 12 threads this does not affect much.
// Strange are the situations if not understood properly.
// Yoda strikes again

在多线程模块中!:)

我经常发现这个

// fix it!

我个人最喜欢的是打油诗形式的文档:

        Subclassing made Zope and TR
        much harder to work with by far.
            So before you inherit,
            be sure to declare it
        Adapter, not PyObject*

这可能会破坏这个笑话,但由于它有点晦涩,我将解释:

这里的TR指的是“扭曲的现实”。Zope 2和最初的扭曲。Reality包大量而不幸地使用了多重继承,这可能会使您在看到方法调用时难以理解发生了什么。Zope 3,扭曲自己,扭曲。现实的后继者(包括最近的假想)通常更倾向于组件组合。