PsiElement (ASTNode node, PsiFile file) { node.putUserData(TreeUtil.CONTAINING_FILE_KEY_AFTER_REPARSE, ((PsiFileImpl)file).getTreeElement()); PsiElement psiChild = file.isPhysical() ? node.getPsi() : null; node.putUserData(TreeUtil.CONTAINING_FILE_KEY_AFTER_REPARSE, null); return psiChild; }