void makeStatic() {
        final PsiModifierList modifiers = innerClass.getModifierList();
        if (modifiers == null) {
          return;
        }
        modifiers.setModifierProperty(PsiModifier.STATIC, true);
        final Project project = innerClass.getProject();
        final JavaCodeStyleManager codeStyleManager = JavaCodeStyleManager.getInstance(project);
        final PsiElementFactory factory = JavaPsiFacade.getElementFactory(project);
        references.stream()
          .sorted((r1, r2) -> PsiUtilCore.compareElementsByPosition(r2, r1))
          .forEach(reference -> {
            final PsiElement parent = reference.getParent();
            if (parent instanceof PsiNewExpression newExpression) {
              final PsiJavaCodeReferenceElement classReference = newExpression.getClassReference();
              if (classReference == null) {
                return;
              }
              final PsiExpressionList argumentList = newExpression.getArgumentList();
              if (argumentList == null) {
                return;
              }
              final PsiReferenceParameterList parameterList = classReference.getParameterList();
              final String genericParameters = parameterList != null ? parameterList.getText() : "";
              final String text = "new " + classReference.getQualifiedName() + genericParameters + argumentList.getText();
              final PsiExpression expression = factory.createExpressionFromText(text, innerClass);
              codeStyleManager.shortenClassReferences(newExpression.replace(expression));
            }
            else if (reference instanceof PsiJavaCodeReferenceElement ref) {
              removeTypeArguments(ref);
            }
          });
      }
void makeStatic()