PsiElement (@NotNull PsiElement element) { // For some reason smart pointers don't work for non-physical (in particular, generated) elements myRootElement = element; findAndReplaceFromImports(element); return myRootElement; }