Object () { CompositeElement treeElement = calcTreeElement(); CompositeElement treeElementClone = (CompositeElement)(treeElement.getTreeParent() != null ? treeElement.copyElement() : treeElement.clone()); /* if (treeElementClone.getPsiElement() != null) { return treeElementClone.getPsiElement(); } */ return cloneImpl(treeElementClone); }