protected static void addRangeWithinContainer(PsiCodeBlock codeBlock, PsiElement container, PsiElement[] statements, boolean canBreak) {
    if (container instanceof PsiSwitchLabeledRuleStatement && statements.length == 1) {
      PsiElement statement = statements[0];
      if (statement instanceof PsiExpressionStatement && canBreak) {
        addYield(codeBlock, (PsiExpressionStatement)statement);
        return;
      }
      if (statement instanceof PsiBlockStatement) {
        addCodeBlockContents(codeBlock, (PsiBlockStatement)statement);
        return;
      }
    }

    codeBlock.addRange(statements[0], statements[statements.length - 1]);
  }
protected static void addRangeWithinContainer(PsiCodeBlock codeBlock, PsiElement container, PsiElement[] statements, boolean canBreak)