@Override
  public void visitRegExpNamedGroupRef(RegExpNamedGroupRef groupRef) {
    if (!(groupRef.getParent() instanceof RegExpConditional) && !myLanguageHosts.supportsNamedGroupRefSyntax(groupRef)) {
      myHolder.newAnnotation(HighlightSeverity.ERROR,
                             RegExpBundle.message("error.this.named.group.reference.syntax.is.not.supported.in.this.regex.dialect"))
        .create();
      return;
    }
    if (groupRef.getGroupName() == null) {
      return;
    }
    final RegExpGroup group = groupRef.resolve();
    if (group == null) {
      final ASTNode node = groupRef.getNode().findChildByType(RegExpTT.NAME);
      if (node != null) {
        myHolder.newAnnotation(HighlightSeverity.ERROR, RegExpBundle.message("error.unresolved.named.group.reference")).range(node)
        .highlightType(ProblemHighlightType.LIKE_UNKNOWN_SYMBOL).create();
      }
    }
    else if (PsiTreeUtil.isAncestor(group, groupRef, true)) {
      myHolder.newAnnotation(HighlightSeverity.WARNING,
                             RegExpBundle.message("error.group.reference.is.nested.into.the.named.group.it.refers.to")).create();
    }
  }
@Override
  public void visitRegExpNamedGroupRef(RegExpNamedGroupRef groupRef)