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


当前回答

} catch (PartInitException pie) {
    // Mmm... pie

其他回答

// TODO: Implement this function!

我最喜欢的是这样的

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

我看到一些旧的fortran代码:

     integer *4 one,two,three;

c    asssign one to 100 before entering the loop
     one=100;

在PeopleSoft Financials PeopleCode的早期版本中:

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

我最喜欢的评论是我的一个同性恋朋友说的。他喜欢用VB标记他所有的TODO注释。净,

'TODO: Matt Damon

有时会提供额外的信息,但通常不是这样。