docs: @Nullable
    public static AnnotationType getAnnotationType(
        AnnotationTree anno, @Nullable Symbol target, VisitorState state) {
      if (target == null) {
        return null;
      }
      Symbol annoSymbol = getSymbol(anno);
      if (annoSymbol == null) {
        return null;
      }
      Compound compound = target.attribute(annoSymbol);
      if (compound == null) {
        for (TypeCompound typeCompound : target.getRawTypeAttributes()) {
          if (typeCompound.type.tsym.equals(annoSymbol)) {
            compound = typeCompound;
            break;
          }
        }
      }
      if (compound == null) {
        return null;
      }
      return TypeAnnotations.instance(state.context).annotationTargetType(compound, target);
    }