← All recipes
Moderne licensed

Parenthesize not pattern for clarity

Recipe IDOpenRewrite.Recipes.CSharp.CodeQuality.Style.ParenthesizeNotPatternArtifactOpenRewrite.Recipes.CSharp.CodeQuality

Add parentheses to not A or B(not A) or B to clarify that not binds tighter than or.

Single recipecsharpstylecode-qualityProprietary

Usage

This recipe has no required configuration options. You’ll need the Moderne CLI configured before running the command below.

mod run . --recipe OpenRewrite.Recipes.CSharp.CodeQuality.Style.ParenthesizeNotPattern

If the recipe isn’t available locally, install it with:

mod config recipes nuget install OpenRewrite.Recipes.CSharp.CodeQuality