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


当前回答

在makefile中找到这个

# ===== Never edit below this line. Ever. Or I'll kick your ass. ====

其他回答

这是我自己代码中的一个,但它仍然非常有趣,我认为最好还是把它放在网上,因为它是在公共SVN中。

// These were orginally up and down. When it was clear the names were
// inapplicable, they were renamed to retain the joke.
// Sorry if you were hoping for useful variable names.
quantum strange, charm;

在OLTP数据库事务的主要触发代码中找到:

-- This line negates the @inverseqty, which is the
-- negative of the @insertedquantity.  This works through the
-- magic of the trigger.  In fact, this code is a lot like
-- the bermuda triangle!
@negquantity = -1 * @inverseqty
/* Please work */

在给一个朋友看了这篇来自《Coding Horror》的文章几个小时后,我看到了他对代码的评论:

// valdez先生是一个暴力的精神病患者。别惹他生气。

来自usenet的经典:

Teradyne硬件建模器代码的深层是一个例程 一大堆十六进制数字到SYS$QIO调用中。唯一的评论是 “这里发生了奇怪的魔法”。