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


当前回答

摘自UNIX版本6源代码,大约1975年:

/* You are not expected to understand this. */

其他回答

我的精选集:

// Thats the end of the While loop
// Clean up last row.  I really must program better than this.

// Note: You can't immediately tell if the line below works.

// Rounding - blech.  It's assumed that all .5s are rounded up.

// Sort out predictions first.  Seems like the right place for a prediction, 'first'.

// Let's interpret!

这是众所周知的,但我喜欢它(在sys/ufs/ufs_vnops.c中):

/*
 * A virgin directory (no blushing please).
 */

在FreeBSD内核源代码树中(甚至在之前,回到4.xBSD)

我刚刚注意到自己在写这个

// not brilliant solution, but fair enough heh.
// Added because boss changed his mind : 20020111,20020501,20020820, ...
// Commented out because boss changed his mind : 20020201,20020614,20020908, ...

在ETL脚本之间的主要黑客RPG数据库和SQL Server一个。我大概有10到20次这样的评论……

//This code sucks, you know it and I know it.  
//Move on and call me an idiot later.