PsiElement (@NotNull PsiElement element) { if (element instanceof PsiJavaReference) { PsiElement resolved = ((PsiJavaReference)element).resolve(); if (resolved != null) return resolved; } return element; }