private static boolean isAccepted(XPathExpression expr) {
            final XmlAttribute attribute = PsiTreeUtil.getContextOfType(expr, XmlAttribute.class, true);
            return attribute != null && !XsltSupport.isPatternAttribute(attribute);
        }
private static boolean isAccepted(XPathExpression expr)