[java-inspections] AbstractClassNeverImplementedInspection: suppress for deprecated abstract classes

GitOrigin-RevId: 4c6f5eeec061cebd203a27ae845c9a4cf394ac6b
This commit is contained in:
Tagir Valeev
2024-07-09 13:51:59 +02:00
committed by intellij-monorepo-bot
parent 26437b1785
commit bc024ed383
2 changed files with 7 additions and 1 deletions

View File

@@ -51,6 +51,9 @@ public final class AbstractClassNeverImplementedInspection extends BaseInspectio
if (InheritanceUtil.hasImplementation(aClass)) {
return;
}
if (aClass.isDeprecated()) {
return;
}
registerClassError(aClass);
}
}

View File

@@ -5,4 +5,7 @@ abstract class AbstractClassWithOnlyOneDirectInheritor {}
class Inheritor extends AbstractClassWithOnlyOneDirectInheritor {}
abstract class AbstractClassWithTwoInheritors {}
class Inheritor1 extends AbstractClassWithTwoInheritors {}
class Inheritor2 extends AbstractClassWithTwoInheritors {}
class Inheritor2 extends AbstractClassWithTwoInheritors {}
@Deprecated
abstract class DeprecatedAbstractClass {}