[java] Deprecate AvoidDeeplyNestedIfStmts #3295
Labels
is:deprecation
The main focus is deprecating public APIs or rules, eg to make them internal, or removing them
Milestone
Is your feature request related to a problem? Please describe.
The rule AvoidDeeplyNestedIfStmts feels really random compared to the several other complexity rules we have (CyclomaticComplexity, NPathComplexity, soon CognitiveComplexity #3293). There's no proper justification for how it works, it just cares about if statements (and not if/else statements, or nesting of other statements). I think it's really superfluous.
Edit: Also there is CollapsibleIfStatements which at least suggests a decent fix.
Describe the solution you'd like Deprecate and remove AvoidDeeplyNestedIfStmts. Hint at using one of the other complexity rules.
Describe alternatives you've considered find a satisfactory definition and justification for the rule, but this feels like a waste of time given the other existing rules.
Additional context
The text was updated successfully, but these errors were encountered: