PsiElement (@NotNull PsiElement expression) { final PyElementGenerator generator = PyElementGenerator.getInstance(myPyString.getProject()); return generator.createExpressionFromText(LanguageLevel.forElement(myPyString), "(" + expression.getText() + ")"); }