@Override
      public void visitCodeReferenceElement(@NotNull GrCodeReferenceElement reference) {
        super.visitCodeReferenceElement(reference);
        if (reference.getQualifier() == null) {
          final PsiElement resolved = reference.resolve();
          if (resolved instanceof PsiTypeParameter typeParameter) {
            if (PsiTreeUtil.isAncestor(typeParameter.getOwner(), element, false)) {
              used.add(typeParameter);
            }
          }
        }
      }
@Override
      public void visitCodeReferenceElement(@NotNull GrCodeReferenceElement reference)