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


当前回答

我只是在一个非常简单的大学课程测试c++程序中碰到了这个。

我在评论一个类。

在析构函数中…

// Choose! Choose the form of the Destructor!
// The choice is made! The Traveler has come!

其他回答

#如你所见:我注释了代码!

// insert comment here
/*
This isn't the right way to deal with this, but today is my last day, Ron
just spilled coffee on my desk, and I'm hungry, so this will have to do...
*/

return 12; // 12 is my lucky number
#define SHIT_HAPPENED (BASE + 1)   /* generic shit happened */
// error codes
#define ERROR_SUCESS 0
#define ERROR_SUCCESS_IS_MISSPELLED 1

没有定义其他错误代码。