A comment marks work left to do with TODO, FIXME or XXX
What it finds
/* TODO: handle errors */: work that was left for later, which a tracker keeps better than the code does. The markers must be written in capitals as words of their own.
From the rule's source, todo_comment.rs.
int f(int a){ /* TODO handle negative values */ return a;tx0 reports: marks work left to do} /* The todo list is kept elsewhere. */ Turn it on, off or suppress it
The rule runs from the strict tier up. To turn it on in a lower tier, give it a level in tx0.toml:
[rules]
"tx0/c:todo-comment" = "warning"To keep one finding, suppress it with a reason. tx0 suppress ID --reason "..." writes the comment on the line before the code:
// tx0: ignore[tx0/c:todo-comment] reason="..."tx0 explain tx0/c:todo-comment shows the same in the terminal. Found a false positive? Report it.