int (@NotNull PsiClass superClass, @NotNull PsiClass subClass) { int numberOfHops = 0; while (true) { if (subClass.equals(superClass)) return numberOfHops; PsiClass next = subClass.getSuperClass(); if (next == null) return -1; numberOfHops++; subClass = next; } }