8390112: Protected static access resolves to a wrong static method - #1150
8390112: Protected static access resolves to a wrong static method#1150dbalek wants to merge 2 commits into
Conversation
|
👋 Welcome back dbalek! A progress list of the required criteria for merging this PR into |
|
@dbalek This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be: You can use pull request commands such as /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 2 new commits pushed to the
Please see this link for an up-to-date comparison between the source branch of this pull request and the As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@asotona, @PaulSandoz) but any other Committer may sponsor as well. ➡️ To flag this PR as ready for integration with the above commit message, type |
Webrevs
|
|
/integrate |
|
/sponsor |
|
Going to push as commit 6d1be28.
Your commit was automatically rebased without conflicts. |
|
@PaulSandoz @dbalek Pushed as commit 6d1be28. 💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored. |
Consider the following code snippets:
When generating bytecode for a protected static method invocation from a different package, the generator uses the lookup class as the receiver of
findStatic. This could resolve a method declared on the accessing class instead of the referenced class.The proposal is to modify
BytecodeGeneratorto use the referenced class for protected static method-handle lookups. A regression test covers resolving and invoking a protected static method declared by a superclass in another package.Progress
Issue
Reviewers
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/babylon.git pull/1150/head:pull/1150$ git checkout pull/1150Update a local copy of the PR:
$ git checkout pull/1150$ git pull https://git.openjdk.org/babylon.git pull/1150/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 1150View PR using the GUI difftool:
$ git pr show -t 1150Using diff file
Download this PR as a diff file:
https://git.openjdk.org/babylon/pull/1150.diff
Using Webrev
Link to Webrev Comment