PsiElement () { final PsiClass containingClass = getContainingClass(); if (containingClass == null) return this; PsiClass originalClass = (PsiClass)containingClass.getOriginalElement(); final PsiMethod originalMethod = originalClass.findMethodBySignature(this, false); return originalMethod != null ? originalMethod : this; }