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


当前回答

在一堆糟糕的剪切和粘贴源代码的内容管理web应用程序:

// load image 1 - JPEG 240x320
img = f1.getImage();
if (check(img))
{
   load(img, Constants.JPEG_240x320);
}

// load image 2 - JPEG 128x128
img = f2.getImage();
if (check(img))
{
   load(img, Constants.JPEG_128x128);
}

...

// load image 13 - GIF 256x256
img = f13.getImage();
if (check(img))
{
   load(img, Constants.GIF256x256);
}

// loaded all of the f**king images

注:大致翻译自意大利语:-)

其他回答

// Empty constructor to satisfy the stupid compiler
 Public ServletHandlerClass () { } 
// now that's compact!
list->insert(list->end(),**pitch)->IdxOfSample=(pitch->pos-Offset)*SamplingRate;

一个名为monitoring.sh的文件的前两行:

#!/usr/bin/perl
# perl script disguised as a bash script
$dnstime = time() + 60 * 60 * 24 * 7 * 2; //how long are you staying for vacation on mars? twooo weeeeeks. give dees people air
#define FUCK_VS6_CANT_COMPILE_TEMPLATES_WITHOUT_HANDHOLDING ((float*)0)

... 

SetPinsFromChannels`<float`>(&pinbuf, streambuf, &inmapper, FUCK_VS6_CANT_COMPILE_TEMPLATES_WITHOUT_HANDHOLDING);