<div dir="ltr"><div dir="ltr">On Thu, Feb 16, 2023 at 2:41 PM Alex Buckley <<a href="mailto:alex.buckley@oracle.com">alex.buckley@oracle.com</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Correct. The `@A` in `@A class B {}` is a declaration annotation, hence <br>
appears in a RuntimeVisibleAnnotations attribute in B.class.<br>
<br>
The next line in 9.7.4 is:<br>
<br>
   A type annotation is an annotation that applies to a type<br>
   (or any part of a type), and whose annotation interface is<br>
   applicable in type contexts.<br>
<br>
Since this `@A` doesn't apply to a type, it's not a type annotation, <br>
hence there is no RuntimeVisibleTypeAnnotations attribute.<br></blockquote><div><br></div><div>How very interesting. So in pragmatic terms, merely looking at an annotation's @Target annotation does not, by itself, tell you all the places it could be used or where it might show up reflectively. I learn something new every day. Thanks for your patience and time.</div><div><br></div><div>Best,</div><div>Laird</div></div></div>