only-used-in-recursion Disallow parameters used only to calculate their own recursive argument A parameter read only to calculate its corresponding recursive argument does not affect the result. Instead, you SHOULD remove the parameter and its argument from every recursive call. - Category: suspicious - Level: warning - Fix: none - Scope: module Reported function depth(remaining: int32, unused: int32): int32 { if (remaining === 0) { return 0; } return depth(remaining - 1, unused); } Accepted function depth(remaining: int32): int32 { if (remaining === 0) { return 0; } return depth(remaining - 1); } Prior art - Clippy · onlyusedinrecursion - Oxc · only-used-in-recursion language/linter/src/rules/suspicious/onlyusedinrecursion.rs:7