Earlier quoted context omitted.
To me, FIX implies that something is wrong, not that it works but could use improvement. I would like to have a tag for "here's something that works, but could be improved" though!
Pray tell, what line would you NOT put that tag on? That's like, all code...
The Linux codebase has over 3k TODO comments, many from over a decade ago
31–40 of 301 posts
Re: The Linux codebase has over 3k TODO comments, many from over a decade ago
#32 #if DEBUG
#define TODO(msg)
#else
#define TODO(msg) #error msg
#endif
Works like a charm. I've got another PRERELEASE() macro that lets you do an unofficial preview build, but would break an official stable release.Re: The Linux codebase has over 3k TODO comments, many from over a decade ago
#33In my opinion, any comment prefixed by TODO, XXX, or the like should not survive past the review stage. Either fix the problem immediately or accept that it's going to be wonky forever. Edit: Amending here to avoid replying to ten different threads individually. 1. Long-term improvements should be managed by a ticket tracking system. The code is not the correct place to manage that. 2. Most of the disagreements below…
Re: The Linux codebase has over 3k TODO comments, many from over a decade ago
#34Earlier quoted context omitted.
Serious question as someone who drops XXX occasionally: There are all sort of places where you want to note "there's probably a better way to do this" or "maybe look at this edge case" or whatever. Not all of those are important enough to address in the next review/sprint/whatever...why isn't it better to leave them in and keep that tribal knowledge around rather that delete them and loose that insight? Maybe a bette…
I think these sorts of notes belong somewhere external of the code itself; an issue ticketing system or whatnot. Because more often than not, I find those "TODO"s lose meaning over time. They often suggest a particular way to solve something, but by the time we might come back to fixing it, that solution is no longer the best way to do it. A ticket can better express the problem , so that we can evaluate and triage h…
Re: The Linux codebase has over 3k TODO comments, many from over a decade ago
#35In my opinion, any comment prefixed by TODO, XXX, or the like should not survive past the review stage. Either fix the problem immediately or accept that it's going to be wonky forever. Edit: Amending here to avoid replying to ten different threads individually. 1. Long-term improvements should be managed by a ticket tracking system. The code is not the correct place to manage that. 2. Most of the disagreements below…
Re: The Linux codebase has over 3k TODO comments, many from over a decade ago
#36Earlier quoted context omitted.
To me, FIX implies that something is wrong, not that it works but could use improvement. I would like to have a tag for "here's something that works, but could be improved" though!
Pray tell, what line would you NOT put that tag on? That's like, all code...
Re: The Linux codebase has over 3k TODO comments, many from over a decade ago
#37Re: The Linux codebase has over 3k TODO comments, many from over a decade ago
#38In my opinion, any comment prefixed by TODO, XXX, or the like should not survive past the review stage. Either fix the problem immediately or accept that it's going to be wonky forever. Edit: Amending here to avoid replying to ten different threads individually. 1. Long-term improvements should be managed by a ticket tracking system. The code is not the correct place to manage that. 2. Most of the disagreements below…
When code has potential issues, I want it to be marked with TODO which basically says "The original developer was not an idiot, but was working with limited resource and the best way to fix the issue wasn't clear then."
Re: The Linux codebase has over 3k TODO comments, many from over a decade ago
#39I use TODO in my code all the time as shorthand for: "This code is functional, but if you are going to do another iteration you may want to consider the following improvement or optimization." It's not at all meant to be to be like an item in a TODO list. Code would be a terrible place to keep that.