你遇到过的源代码中最好的注释是什么?
当前回答
我在我发布的WordPress模板中发布了这个“许可声明”。不管怎样,我觉得这很有趣。
/* The License:
You (from this point on referred to as The You) are hereby
granted by me (from this point on referred to as The Me)
license to knock yourself silly with this template.
By using this template The You implicitly accepts this
license and pledges solemnly to never claim creative
ownership of any graphics, code, concepts, eggs, bacon, ideas,
colors, shapes, hypertext-transfer protocols or other conduits
of the visual splendor thatis this template.
The Me, in turn, pledges equally solemnly to be far too
lazy to ever check up on you, so if you do manage to pull
some chicks The Me won't have a cow.
However The Me would be sorely disappointed if The You
were to try and sell or distribute this work without
acknowledging The Me. Seriously. The Me will come down on
The You like a large quantitiy of hard and heavy objects
that in large quantities may be harmful and possibly even
lethal to The You; So don't even think about it, The Buster.
*/
其他回答
来自sendmail配置文件。一页又一页看起来就像线条噪音。我发现了这块宝石。
# insert this handy debugging line wherever you have problems
#R$* $:$>99$1
if(m_measures =/*=*/ --index)
{
....
// I have to find a better job
经典ASP:
'Is it worth it, let me work it'
'I put my thing down, flip it and reverse it'
'Ti esrever dna ti pilf, nwod gniht ym tup I'
NextIP = StrReverse(UserRecordset.Fields.Item(0))
这是我们团队微观管理效果的一个活生生的例子:
// I am not responsible of this code.
// They made me write it, against my will.
... 我们敬爱的技术总监很喜欢把代码和编码指南都硬塞到开发人员的喉咙里(*)。
当然,当项目负责人寻找bug的原因时,发现它在“非最佳代码”中,他就不那么高兴了……
(*)当然,我指的是强大的VB国王……如果你想评估强大的VB国王的全部力量,你可以阅读下面的SO帖子:你被迫遵循的最奇怪的编码标准规则是什么?...
推荐文章
- 在构建中编写注释的语法是什么?gradle文件?
- Java注释中的/**和/*
- 有没有办法注释掉.ASPX页面中的标记?
- Jenkins:注释可以添加到Jenkins文件中吗?
- TypeScript注释的语法记录在哪里?
- CSV文件可以有注释吗?
- 什么是自文档化代码?它能取代文档化良好的代码吗?
- 在erb中添加注释的最佳方法
- 为什么Python没有多行注释?
- 我应该在批处理文件中使用哪种注释风格?
- 如何在Office VBA编辑器中注释和取消注释代码块
- “# noqa”在Python注释中是什么意思?
- 我可以向pip需求文件添加注释吗?
- 你遇到过的源代码中最好的注释是什么?
- 在Bash中创建多行注释的方法?