redundant-pattern-matching Prefer canonical result predicates over boolean pattern matches A match that maps Ok and Err directly to opposite boolean values only tests the result variant. Instead, you SHOULD call isOk() or isErr() on the result. - Category: suspicious - Level: warning - Fix: suggestion - Scope: module Reported function succeeded(result: Result): boolean { return match (result) { Ok { value: _ } => true Err { error: _ } => false }; } Accepted function succeeded(result: Result): boolean { return result.isOk(); } Prior art - Clippy ยท redundantpatternmatching language/linter/src/rules/suspicious/redundantpatternmatching.rs:8