private List<TypeAnnotation> getPossibleTypeAnnotationCollisions(@NotNull Type type) {
    return Arrays.stream(StructGeneralAttribute.TYPE_ANNOTATION_ATTRIBUTES)
      .flatMap(attrKey -> {
        StructTypeAnnotationAttribute attribute = (StructTypeAnnotationAttribute)getAttribute(attrKey);
        if (attribute == null) {
          return Stream.empty();
        } else {
          return attribute.getAnnotations().stream();
        }
      })
      .filter(ta -> ta.isWrittenBeforeType(type))
      .collect(Collectors.toList());
  }
private List<TypeAnnotation> getPossibleTypeAnnotationCollisions(@NotNull Type type)