RFR: 8303431: [JVMCI] libgraal annotation API [v7]

Doug Simon dnsimon at openjdk.org
Mon Apr 17 20:27:08 UTC 2023


On Mon, 17 Apr 2023 15:48:53 GMT, Joe Darcy <darcy at openjdk.org> wrote:

>> Doug Simon has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   [skip ci] formatting fixes
>
> src/java.base/share/classes/jdk/internal/vm/VMSupport.java line 419:
> 
>> 417:      * @param <X> type of the object representing a decoded error
>> 418:      */
>> 419:     public interface AnnotationDecoder<T, A, E, X> {
> 
> I think it would be better to include some bound on the type parameters to better capture their intention
> A extends java.lang.Annotatoin
> E extends java.lang.Enum
> etc.

These types are *alternatives* to `java.lang.Annotation`, `java.lang.Enum` etc. That's the primary motivation for this PR, i.e. to be able to represent annotations without having to reify them as `java.lang.Annotation` objects.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/12810#discussion_r1169232602


More information about the core-libs-dev mailing list