PsiNewExpression (PsiElement element) { if (element instanceof PsiNewExpression) { return (PsiNewExpression)element; } for (PsiElement child = element.getFirstChild(); child != null; child = child.getNextSibling()) { final PsiNewExpression expression = findNewExpression(child); if (expression != null) return expression; } return null; }