|
-
Apr 22nd, 2013, 06:25 AM
#11
Re: Note to community
I was pretty explicit in my first post that I was referring to .NET code specifically because I don't know how easy it is to write this style of code in VB6. The .NET code that is exposed through COM has a public contract that it must honour. I don't think it's relevant what uses the code, but rather what invariants should it guarantee? Who cares whether the method is used by system XYZ or system ABC? The point of COM would be that the code can be consumed by anything that talks COM. If a new application uses the component, are you required to update the comments in the source code?
That said, I don't use COM, so it may not be so appropriate to have comment-less code at the very public interface, however the implementation of that interface I would definitely strive for code that doesn't need commenting. So try again, post some .NET code with comments where you think the comments are necessary, and I'll show you how I would rearrange the code so that it doesn't need those comments
[Edit: Also, I'm not sure you've understood me. I'm not saying "write code without comments", I'm saying "write your code in such a way that it does not need comments". The information in your comments would still be present, just in a different form (usually method names).]
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|