Simplify redundant logical expression

Proprietary

Simplify x && x to x, x || x to x, and similarly for & and |, where both sides of a logical or bitwise operator are identical.

OpenRewrite.Recipes.CSharp.CodeQuality.Simplification.SimplifyRedundantLogicalExpression
mod run . --recipe=OpenRewrite.Recipes.CSharp.CodeQuality.Simplification.SimplifyRedundantLogicalExpression

Install it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.