@NotNull
  protected Collection<KotlinType> computeSupertypes() {
    if (KotlinBuiltIns.isSpecialClassWithNoSupertypes(this)) {
      return Collections.emptyList();
    }

    KtClassOrObject classOrObject =
        declarationProvider.getOwnerInfo().getCorrespondingClassOrObject();
    if (classOrObject == null) {
      return Collections.<KotlinType>singleton(c.getModuleDescriptor().getBuiltIns().getAnyType());
    }

    List<KotlinType> allSupertypes =
        c.getDescriptorResolver()
            .resolveSupertypes(
                getScopeForClassHeaderResolution(), this, classOrObject, c.getTrace());

    return Lists.newArrayList(Collections2.filter(allSupertypes, VALID_SUPERTYPE));
  }