Skip to content

8261625: Add Elements.isAutomaticModule(ModuleElement) #3382

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 6 commits into from

Conversation

jddarcy
Copy link
Member

@jddarcy jddarcy commented Apr 7, 2021

Addition of a small convenience method, with a default implementation, to Elements.

Most of the change is testing infrastructure. The negative cases, such as named modules, are tested in the style of other annotation processing tests for Elements utilities.

An automatic module comes from a jar file, so an API reading from a jar file is needed. To avoid piping in the awkward plumbing needed to do that directly in the annotation processing tests, I updated an existing automatic modules test which uses the tool box facility. My additions to the tool box might not be the done in the most idiomatic style for that API; happy to have guidance on how to proceed better there.

Assuming this general approach is agreed to, I'll update the imports on AutomaticModules.java to condense the text of the annotation processor source.


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8261625: Add Elements.isAutomaticModule(ModuleElement)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk pull/3382/head:pull/3382
$ git checkout pull/3382

Update a local copy of the PR:
$ git checkout pull/3382
$ git pull https://git.openjdk.java.net/jdk pull/3382/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 3382

View PR using the GUI difftool:
$ git pr show -t 3382

Using diff file

Download this PR as a diff file:
https://git.openjdk.java.net/jdk/pull/3382.diff

@bridgekeeper
Copy link

bridgekeeper bot commented Apr 7, 2021

👋 Welcome back darcy! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot changed the title 8261625: Add `Elements.isAutomaticModule(ModuleElement) 8261625: Add Elements.isAutomaticModule(ModuleElement) Apr 7, 2021
@openjdk openjdk bot added the rfr Pull request is ready for review label Apr 7, 2021
@openjdk
Copy link

openjdk bot commented Apr 7, 2021

@jddarcy The following label will be automatically applied to this pull request:

  • compiler

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added the compiler compiler-dev@openjdk.org label Apr 7, 2021
@mlbridge
Copy link

mlbridge bot commented Apr 7, 2021

Webrevs

@jddarcy
Copy link
Member Author

jddarcy commented Apr 7, 2021

PS And the CSR should be reviewed as well:

https://bugs.openjdk.java.net/browse/JDK-8264865

Thanks.

@@ -0,0 +1,125 @@
/*
* Copyright (c) 2006, 2021, Oracle and/or its affiliates. All rights reserved.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2006 can be removed

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I copied a file from 2006 and then edited the result, hence I started with the 2006 year.

@vicente-romero-oracle
Copy link
Contributor

/csr

@openjdk openjdk bot added the csr Pull request needs approved CSR before integration label Apr 8, 2021
@openjdk
Copy link

openjdk bot commented Apr 8, 2021

@vicente-romero-oracle this pull request will not be integrated until the CSR request JDK-8264865 for issue JDK-8261625 has been approved.

Copy link
Contributor

@vicente-romero-oracle vicente-romero-oracle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link
Contributor

@lahodaj lahodaj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@openjdk openjdk bot removed the csr Pull request needs approved CSR before integration label Apr 8, 2021
@jddarcy
Copy link
Member Author

jddarcy commented Apr 8, 2021

/integrate

@openjdk
Copy link

openjdk bot commented Apr 8, 2021

@jddarcy 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:

8261625: Add `Elements.isAutomaticModule(ModuleElement)`

Reviewed-by: vromero, jlahoda

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 13 new commits pushed to the master branch:

  • 5bd6c74: 8236127: Use value of --icon CLI option to set icon for exe installers
  • 81d35e4: 8264063: Outer Safepoint poll load should not reference the head of inner strip mined loop.
  • 04fa1ed: 8264848: [macos] libjvm.dylib linker warning due to macOS version mismatch
  • 214d6e2: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable
  • af13c64: 8264711: More runtime TRAPS cleanups
  • 3aec2d9: 8264718: Shenandoah: enable string deduplication during root scanning
  • 255afbe: 8264672: runtime/ParallelLoad/ParallelSuperTest.java timed out
  • ec599da: 8264633: Add missing logging to PlatformRecording#stop
  • e89542f: 8264352: AArch64: Optimize vector "not/andNot" for NEON and SVE
  • 016db40: 8263907: Specification of CellRendererPane::paintComponent(..Rectangle) should clearly mention which method it delegates the call to
  • ... and 3 more: https://git.openjdk.java.net/jdk/compare/6e2b82a45f2f86c45fe62dcc6cf5cb979b8a5366...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Apr 8, 2021
@openjdk openjdk bot closed this Apr 8, 2021
@openjdk openjdk bot added integrated Pull request has been integrated and removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Apr 8, 2021
@openjdk
Copy link

openjdk bot commented Apr 8, 2021

@jddarcy Since your change was applied there have been 15 commits pushed to the master branch:

  • 8a23580: 8264428: Cleanup usages of StringBuffer in java.desktop
  • 308f679: 8264454: Jaxp unit test from open jdk needs to be improved
  • 5bd6c74: 8236127: Use value of --icon CLI option to set icon for exe installers
  • 81d35e4: 8264063: Outer Safepoint poll load should not reference the head of inner strip mined loop.
  • 04fa1ed: 8264848: [macos] libjvm.dylib linker warning due to macOS version mismatch
  • 214d6e2: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable
  • af13c64: 8264711: More runtime TRAPS cleanups
  • 3aec2d9: 8264718: Shenandoah: enable string deduplication during root scanning
  • 255afbe: 8264672: runtime/ParallelLoad/ParallelSuperTest.java timed out
  • ec599da: 8264633: Add missing logging to PlatformRecording#stop
  • ... and 5 more: https://git.openjdk.java.net/jdk/compare/6e2b82a45f2f86c45fe62dcc6cf5cb979b8a5366...master

Your commit was automatically rebased without conflicts.

Pushed as commit ccefa5e.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@jddarcy jddarcy deleted the 8261625 branch June 10, 2021 20:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compiler compiler-dev@openjdk.org integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

3 participants