PsiElementVisitor (@NotNull final ProblemsHolder holder, boolean isOnTheFly) { return new XmlElementVisitor() { @Override public void visitXmlTag(final @NotNull XmlTag tag) { if (tag instanceof HtmlTag) { return; } final ASTNode child = XmlChildRole.START_TAG_END_FINDER.findChild(tag.getNode()); if (child == null) { return; } final ASTNode node = child.getTreeNext(); if (node != null && node.getElementType() == XmlTokenType.XML_END_TAG_START) { holder.registerProblem( tag, XmlAnalysisBundle.message("xml.inspections.tag.empty.body"), LocalQuickFix.notNullElements(isCollapsibleTag(tag) ? new CollapseTagIntention() : null) ); } } }; }