void (@NotNull ActionContext context, @NotNull PsiInstanceOfExpression instanceOfExpression, @NotNull ModPsiUpdater updater) { PsiElement decl = createAndInsertCast(context.offset(), instanceOfExpression); if (decl == null) return; decl = CodeInsightUtilCore.forcePsiPostprocessAndRestoreElement(decl); if (decl == null) return; decl = CodeStyleManager.getInstance(context.project()).reformat(decl); updater.moveTo(decl.getTextRange().getEndOffset()); }