<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On 15 July 2013 22:58, Kenneth Cochran <span dir="ltr"><<a href="mailto:kenneth.cochran@gmail.com" target="_blank">kenneth.cochran@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><div class="gmail_quote"><br><div> </div></div>I completely disagree. It is the code that is the primary expression of intent not the comments. This is mainly accomplished through sensible identifier naming. Comments exist to compensate for a developer's inability to express intent through the code and IMHO should be reserved for this sole purpose. In most cases you should be able to look at a function signature and know exactly what that function's intent is. Likewise you should be able to tell the intent of a class by its name and the names of its public/published members. This is, at least, what I strive for in my own code. Bob Martin's "Clean Code" dedicates the entire 4th chapter to the discussion of comments and make some very compelling arguments for limiting their use.</div>
</div>
<br>_______________________________________________<br>
fpc-pascal maillist - <a href="mailto:fpc-pascal@lists.freepascal.org">fpc-pascal@lists.freepascal.org</a><br>
<a href="http://lists.freepascal.org/mailman/listinfo/fpc-pascal" target="_blank">http://lists.freepascal.org/mailman/listinfo/fpc-pascal</a><br></blockquote></div><br></div><div class="gmail_extra">I have 2 main concerns here, a comment for the component itself which is not particularly important and a comment for the component when I add it to a form or data module. When I create a method I can add a comment to the method. If I create a component in code, I can label that section of code, but if I drag and drop a component from the palette onto the form what option do I have? Descriptive variable and component names have a habit of getting too long. It is hardly for the end users sake unless the enduser is a programmer. I just need something to help when working in the IDE, eg hovering over a component and seeing the comment in addition to what is current displayed.<br clear="all">
</div><div class="gmail_extra"><br>-- <br>Frank Church<br><br>=======================<br><a href="http://devblog.brahmancreations.com">http://devblog.brahmancreations.com</a>
</div></div>