8202471: Resolves generic receiver type for types with generic signatures
David Holmes
david.holmes at oracle.com
Tue Jul 23 04:08:49 UTC 2019
Hi Rafael,
A couple of comments on process here ...
On 23/07/2019 6:48 am, Rafael Winterhalter wrote:
> Hello,
>
> I have created a patch such that getReceiverType() returns a parameterized
> type if the receiver type declaration is itself generic. Currently, the
> receiver type is always a type representation of Class such that
> annotations on the type variables or the receiver type's owner type cannot
> be resolved: https://gist.github.com/raphw/a155d5ef66d11e5fb131b7e6b8fb10e5
All OpenJDK contributions must be provided via OpenJDK infrastructure,
so either direct code in an email to a mailing list (attachments usually
get stripped), or a webrev hosted on cr.openjdk.java.net (available
directly to Authors else find someone to host for you). Links to github
are not acceptable at this time.
> Note that this change can potentially break existing code if callers of the
> method expect this behavior for parameterized receiver types. However,
> without this change, the type information is lost and I would argue that
> the current behavior can be considered to be incorrect.
That argument needs to be made via a Compatibility and Specification
Review (CSR) request:
https://wiki.openjdk.java.net/display/csr/Main
Cheers,
David
> Best regards, Rafael
>
More information about the core-libs-dev
mailing list