public boolean isBaseClassReference(@NotNull PsiElement element) {
    if (element instanceof PsiJavaCodeReferenceElement) {
      // IMPORTANT: do not call getBaseClassReference() for lastParent which is not under our node - loads tree!
      PsiElement parent = element.getParent();
      return parent == this && element == getBaseClassReference() ||
             isBaseClassReferenceHolder(parent);
    }

    return isBaseClassReferenceHolder(element);
  }
public boolean isBaseClassReference(@NotNull PsiElement element)