public static PsiClassType[] getReferenceListTypes(@Nullable GrReferenceList list) {
    if (list == null) return PsiClassType.EMPTY_ARRAY;
    return list.getReferencedTypes();
  }
public static PsiClassType[] getReferenceListTypes(@Nullable GrReferenceList list)