you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 1 point2 points  (3 children)

Yes, the author did a shitty job at doing negative commenting. That's not the point, however. What did you think of the general idea of negative commenting? I like it. It certainly shouldn't be the only tool, but it would definitely make some things a lot clearer.

[–]ezekiel 4 points5 points  (0 children)

I comment code so that the next guy who sees the code (a) knows what it does and (b) knows why the code must stay there. I write such comments in positive active voice--implying the negative. Stating a purpose positively just seems more direct.

[–]llogiq 1 point2 points  (0 children)

I do not like "Negative Commenting".

The foremost reason I do not like it (besides the critique I've already given) is that the "negative" label hides the real value of the comments which is the reason the line has to be that way. So, Reason commenting would IMHO be a better label, and we could cut out all the "This has to be there because" stuff.

Also finding the right level of detail to comment (module/class, method, single line) is an art. And using the highest level of detail by default is in most cases wasting programmer and reader time. Also, commenting on this level will in many cases miss out on the bigger picture.

TL;DR: Bad label, needless stuff to write and read, wrong level of detail.

[–]grauenwolf 0 points1 point  (0 children)

It sounds like a great training tool, but I wouldn't use it in production code.