Closed j-stephan closed 3 years ago
Enable | Disable |
---|---|
1 | 1 |
This one is important. If a codebase gets older, you will have many TODOs in there and your git/SVN log is not helping you with who wrote it, because the code around got refactored, formattet etc. So adding a username to a TODO gives you a chance to still find that person, if the comment was important.
Git blame
will show you the author of the comment.
Git blame
will show you the author of the comment.
No, it will show you the last person who edited the line.
So if I wrote:
func(a, b); // TODO: this might be slow
And you refactor it to, maybe even as part of an automatic rename:
Func(a, b); // TODO: this might be slow
Then git blame will give me your name and not the TODO author's.
Requesting a tie break here. @psychocoderHPC @sbastrakov @SimeonEhrig @sliwowitz or anyone else who has feelings about this...
Ok, I'll do it myself. I actually now think that this is quite useful. Final result:
Enable | Disable |
---|---|
2 | 0 |
Git blame
will show you the author of the comment.
It's also possible to iterate throw the history with git blame and look after the original author of the TODO, but I'm fine, if it is forced by clang-tidy. The consistence check is the time consuming stuff, not writing the comment ;-)
Enable | Disable |
---|---|
3 | 0 |
This PR contains the check related to comments. Voting will end on 17 November 2020, 18:00 HZDR time.
Vote