boolean (PsiElement element) { if (!(element instanceof PsiReferenceList throwsList)) { return false; } if (throwsList.getReferenceElements().length < 2) { return false; } final PsiElement parent = element.getParent(); if (!(parent instanceof PsiMethod method)) { return false; } return method.getThrowsList().equals(element); }