Article 5S84J CodeSOD: Templated Comments

CodeSOD: Templated Comments

by
Remy Porter
from The Daily WTF on (#5S84J)

Mike's company likes to make sure their code is well documented. Every important field, enumeration, method, or class has a comment explaining what it is. You can see how much easier it makes understanding this code:

 /// <summary> /// Provides clear values for Templates /// </summary> public enum TemplateType { /// <summary> /// 1 /// </summary> TEMPLATE_1 = 1, /// <summary> /// 2 /// </summary> TEMPLATE_2 = 2, /// <summary> /// 3 /// </summary> TEMPLATE_3 = 3, /// <summary> /// 6 /// </summary> TEMPLATE_6 = 6, /// <summary> /// 8 /// </summary> TEMPLATE_8 = 8, /// <summary> /// 10 /// </summary> TEMPLATE_10 = 10, /// <summary> /// 12 /// </summary> TEMPLATE_12 = 12, /// <summary> /// 17 /// </summary> TEMPLATE_17 = 17, /// <summary> /// 18 /// </summary> TEMPLATE_18 = 18, /// <summary> /// 20 /// </summary> TEMPLATE_20 = 20, /// <summary> /// 32 /// </summary> TEMPLATE_32 = 32, /// <summary> /// 42 /// </summary> TEMPLATE_42 = 42, /// <summary> /// 54 /// </summary> TEMPLATE_54 = 54, /// <summary> /// 55 /// </summary> TEMPLATE_55 = 55, /// <summary> /// 57 /// </summary> TEMPLATE_57 = 57, /// <summary> /// 73 /// </summary> TEMPLATE_73 = 73, /// <summary> /// 74 /// </summary> TEMPLATE_74 = 74, /// <summary> /// 177 /// </summary> TEMPLATE_177 = 177, /// <summary> /// 189 /// </summary> TEMPLATE_189 = 189 }

There. Clear, consice, and well documented. Everything you need to know. I'm sure you have no further questions.

proget-icon.png [Advertisement] ProGet's got you covered with security and access controls on your NuGet feeds. Learn more. TheDailyWtf?d=yIl2AUoC8zA
External Content
Source RSS or Atom Feed
Feed Location http://syndication.thedailywtf.com/TheDailyWtf
Feed Title The Daily WTF
Feed Link http://thedailywtf.com/
Reply 0 comments