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


当前回答

switch(value)
{
   [...]
default:
   ASSERT(**true**); // if this is triggered, something really bad is happening.
}

其他回答

/* Look not upon this file lest your eyes be burnt from your head. */

我能说什么呢?我当时是实习生,夏天快结束了。我们可以说,我对我的文件责任缺乏认真的承诺。

我最喜欢的是这样的

 # commented out
 ...
 ### end of the formerly uncommented #2001-02-22 John Doe

我最近看到了这个:

//你刚刚输了比赛

如果你不知道游戏是什么: http://en.wikipedia.org/wiki/The_Game_ (mind_game) (这很傻,但在某种程度上很有趣)

#!/usr/bin/sh
#       Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
#         All Rights Reserved

#       THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF AT&T
#       The copyright notice above does not evidence any
#       actual or intended publication of such source code.

#ident  "@(#)false.sh   1.6     93/01/11 SMI"   /* SVr4.0 1.3   */
exit 255

从SunOS 5.9即Solaris 9获取(/usr/bin/false)

在PeopleSoft Financials PeopleCode的早期版本中:

/* I don't know how you can ever get here so I'll have to fix it later */