no-needless-match Disallow matches that reconstruct their scrutinee unchanged A match whose every arm returns the exact value selected by its pattern leaves the scrutinee unchanged. Instead, you SHOULD use the scrutinee directly. - Category: style - Level: warning - Fix: automatic - Scope: module Reported function preserve(value: int32): int32 { return match (value) { 0 => 0 1 => 1 value => value }; } Accepted function preserve(value: int32): int32 { return value; } Prior art - Clippy ยท needlessmatch language/linter/src/rules/style/noneedlessmatch.rs:8