public static @NotNull PsiElement getDeepestLast(@NotNull PsiElement element) {
    PsiElement result = element;
    do {
      PsiElement lastChild = result.getLastChild();
      if (lastChild == null) return result;
      result = lastChild;
    }
    while (true);
  }
public static @NotNull PsiElement getDeepestLast(@NotNull PsiElement element)