public Object @Nullable [] processSwitch(@NotNull PsiSwitchBlock block) {
      final PsiCodeBlock body = block.getBody();
      if (body == null) return null;
      final int branchCount = SwitchUtils.calculateBranchCount(block);
      int notDefaultBranches = branchCount < 0 ? -branchCount - 1 : branchCount;
      if (notDefaultBranches >= m_limit) {
        return null;
      }
      if (branchCount == 0) {
        // Empty switch is reported by another inspection
        return null;
      }
      boolean patternSwitch = ContainerUtil.exists(SwitchUtils.getSwitchBranches(block), e -> e instanceof PsiPattern);
      if (patternSwitch && ignorePatternSwitch) return null;
      if (branchCount > 0 && (patternSwitch || block instanceof PsiSwitchExpression)) {
        // Absence of 'default' branch makes the pattern-switch or expression-switch exhaustive
        // skip reporting in this case, as conversion to if-else or ?: will remove the compile-time
        // exhaustiveness check
        return null;
      }
      boolean fixIsAvailable;
      if (block instanceof PsiSwitchStatement) {
        fixIsAvailable = ConvertSwitchToIfIntention.isAvailable((PsiSwitchStatement)block);
      }
      else {
        PsiStatement[] statements = body.getStatements();
        if (statements.length == 1 && statements[0] instanceof PsiSwitchLabeledRuleStatement statement) {
          fixIsAvailable = SwitchUtils.isDefaultLabel(statement) &&
                           statement.getBody() instanceof PsiExpressionStatement &&
                           (block.getExpression() == null ||
                            !SideEffectChecker.mayHaveSideEffects(block.getExpression()) ||
                            CodeBlockSurrounder.canSurround(block.getExpression()));
        }
        else {
          fixIsAvailable = false;
        }
      }
      return new Object[]{Integer.valueOf(notDefaultBranches), block, fixIsAvailable, patternSwitch};
    }
public Object @Nullable [] processSwitch(@NotNull PsiSwitchBlock block)