@Override
  @NotNull
  public ClassResolveResult resolveGenerics() {
    return new ClassResolveResult() {
      private final PsiClass myBaseClass = resolve();

      private final NotNullLazyValue<PsiSubstitutor> mySubstitutor = NotNullLazyValue.lazy(() -> {
        return inferSubstitutor(myBaseClass);
      });

      @Override
      public PsiClass getElement() {
        return myBaseClass;
      }

      @Override
      @NotNull
      public PsiSubstitutor getSubstitutor() {
        PsiSubstitutor substitutor = doPreventingRecursion(GrLiteralClassType.this, false, () -> mySubstitutor.getValue());
        return substitutor == null ? PsiSubstitutor.EMPTY : substitutor;
      }

      @Override
      public boolean isPackagePrefixPackageReference() {
        return false;
      }

      @Override
      public boolean isAccessible() {
        return true;
      }

      @Override
      public boolean isStaticsScopeCorrect() {
        return true;
      }

      @Override
      @Nullable
      public PsiElement getCurrentFileResolveScope() {
        return null;
      }

      @Override
      public boolean isValidResult() {
        return isStaticsScopeCorrect() && isAccessible();
      }
    };
  }
@Override
  @NotNull
  public ClassResolveResult resolveGenerics()