SmartPsiElementPointer<XmlTag> (Project project, ProblemDescriptor descriptor, boolean reformat) { PsiElement element = descriptor.getPsiElement(); if (element instanceof XmlAttributeValue) { element = element.getParent(); } else if (!(element instanceof XmlAttribute)) { return null; } XmlAttribute attribute = (XmlAttribute)element; XmlTag parent = attribute.getParent(); SmartPsiElementPointer<XmlTag> pointer = SmartPointerManager.getInstance(project).createSmartPsiElementPointer(parent); doRemove(project, attribute, parent); if (reformat) { reformatStartTag(project, pointer); } return pointer; }