JvmMethod (@NotNull JvmClass clazz) { return JvmHierarchyUtil.traverseSupers(clazz, superClazz -> { if (superClazz.getClassKind() == JvmClassKind.INTERFACE) { return null; } return findMainMethodInClass(superClazz); }); }