PsiElement (UsageInfo usage) { ProperTextRange range = usage.getRangeInElement(); assertNotNull(range); PsiElement element = usage.getElement(); assertNotNull(element); PsiElement elementAt = element.findElementAt(range.getStartOffset()); assertNotNull(elementAt); return elementAt.getParent(); }