A comment marks unfinished work with TODO, FIXME or XXX
What it finds
TODO and FIXME mark work that was left for later. Listing them keeps that work visible instead of letting it age in the code unnoticed.
A comment is reported when it contains TODO, FIXME or XXX as a word in upper case. The level is a note, since such a comment is a reminder rather than a defect.
From the rule's source, todo_comment.rs.
export function f() { // TODO: handle errorstx0 reports: marks unfinished work /* FIXME later */ return 1;tx0 reports: marks unfinished work}// The method todos() returns items. 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/ts:todo-comment" = "note"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/ts:todo-comment] reason="..."tx0 explain tx0/ts:todo-comment shows the same in the terminal. Found a false positive? Report it.