Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[java] Deprecate AvoidDeeplyNestedIfStmts #3295

Open
oowekyala opened this issue May 24, 2021 · 0 comments
Open

[java] Deprecate AvoidDeeplyNestedIfStmts #3295

oowekyala opened this issue May 24, 2021 · 0 comments
Labels
is:deprecation The main focus is deprecating public APIs or rules, eg to make them internal, or removing them
Milestone

Comments

@oowekyala
Copy link
Member

oowekyala commented May 24, 2021

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

@oowekyala oowekyala added the is:deprecation The main focus is deprecating public APIs or rules, eg to make them internal, or removing them label May 24, 2021
@oowekyala oowekyala changed the title Deprecate AvoidDeeplyNestedIfStmts [java] Deprecate AvoidDeeplyNestedIfStmts May 24, 2021
@oowekyala oowekyala mentioned this issue Apr 7, 2022
55 tasks
@adangel adangel added this to the 6.54.0 milestone Dec 31, 2022
@adangel adangel modified the milestones: 6.54.0, 7.x Jan 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
is:deprecation The main focus is deprecating public APIs or rules, eg to make them internal, or removing them
Projects
None yet
Development

No branches or pull requests

2 participants