void (@NotNull PsiSwitchLabeledRuleStatement statement) { PsiSwitchBlock switchBlock = statement.getEnclosingSwitchBlock(); if (switchBlock == null) return; startElement(statement); PsiCaseLabelElementList labelElementList = statement.getCaseLabelElementList(); if (labelElementList != null) { for (PsiCaseLabelElement element : labelElementList.getElements()) { if (element instanceof PsiDefaultCaseLabelElement) { element.accept(this); } } } PsiStatement body = statement.getBody(); PsiCodeBlock switchBody = switchBlock.getBody(); boolean expressionSwitch = myExpressionBlockContext != null && myExpressionBlockContext.myCodeBlock == switchBody; if (expressionSwitch && body instanceof PsiExpressionStatement expressionStatement) { myExpressionBlockContext.generateReturn(expressionStatement.getExpression(), this); } else { if (body != null) { body.accept(this); } if (ControlFlowUtils.statementMayCompleteNormally(body)) { jumpOut(expressionSwitch ? switchBody : switchBlock); } } finishElement(statement); }