|
|
|
|
|
by zero_one_one
3175 days ago
|
|
>> if your code needs a comment to be understood, it would be better to rewrite it so it's easier to understand. I both agree and disagree with this... C is a small language, and it shouldn't take a huge amount of time to parse the source code to find out what's going on if variables / function names are self-documenting etc. However, if you're dealing with a large code base and trying to track down where a variable is declared (and subsequently defined) for the purposes of maintenance or updating legacy code, comments hinting the what the structure underneath that label represents are incredibly useful (and more importantly, time and energy saving) |
|