Integrated: 8225488: Examine ExecutableType.getReceiverType behavior when source receiver parameter is absent
Joe Darcy
darcy at openjdk.java.net
Mon Aug 9 18:36:36 UTC 2021
On Tue, 3 Aug 2021 00:06:37 GMT, Joe Darcy <darcy at openjdk.org> wrote:
> A belated companion fix to JDK-8222369, this change updates ExecutableType.getReceiverType to have its specified behavior:
>
> Returns the return type of this executable. Returns a NoType with kind VOID if this executable is not a method, or is a method that does not return a value.
>
> rather than returning null, as the implementation did before. The ExecutableElement implementation in Symbol is updated accordingly to take advantage of the change in Type, along with augmenting the test from JDK-8222369 to cover the receiver type from the ExecutableType too.
>
> BasicAnnoTests.java is updated for revised offsets.
>
> All langtools tests pass with these changes and TestExecutableReceiverType.java fails with an unmodified javac in JDK 18.
>
> Please also review the companion CSR JDK-8271703, https://bugs.openjdk.java.net/browse/JDK-8271703
This pull request has now been integrated.
Changeset: 7fc99cf9
Author: Joe Darcy <darcy at openjdk.org>
URL: https://git.openjdk.java.net/jdk/commit/7fc99cf9b69f99fc78709e57b92cd88e09577d0f
Stats: 34 lines in 4 files changed: 18 ins; 1 del; 15 mod
8225488: Examine ExecutableType.getReceiverType behavior when source receiver parameter is absent
Reviewed-by: jjg
-------------
PR: https://git.openjdk.java.net/jdk/pull/4965
More information about the compiler-dev
mailing list