void (@NotNull XmlElement element, @NotNull ProblemsHolder holder) { PsiReference[] references = element.getReferences(); if (references.length == 0) { return; } if (XmlHighlightVisitor.isInjectedWithoutValidation(element)) { return; } boolean isHtml = HtmlUtil.isHtmlTagContainingFile(element); if (isHtml ^ isForHtml()) { return; } if (!isHtml && XmlHighlightVisitor.skipValidation(element)) { return; } Collection<PsiReference> unresolved = getUnresolvedReferencesToAnnotate(references); for (PsiReference reference : unresolved) { holder.registerProblem(reference, ProblemsHolder.unresolvedReferenceMessage(reference), isHtml ? ProblemHighlightType.GENERIC_ERROR_OR_WARNING : ProblemHighlightType.LIKE_UNKNOWN_SYMBOL); } }