-
Notifications
You must be signed in to change notification settings - Fork 1.8k
[GR-54918] Rename JDK23OrLater to JDKLatest and remove obsolete predicates #9211
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -28,9 +28,13 @@ | |
|
|
||
| import jdk.graal.compiler.serviceprovider.JavaVersionUtil; | ||
|
|
||
| public class JDK22OrEarlier implements BooleanSupplier { | ||
| /** | ||
| * Denotes the latest supported JDK version. It corresponds to the highest key in the | ||
| * {@code JVMCI_MIN_VERSIONS} map in {@link jdk.graal.compiler.hotspot.JVMCIVersionCheck}. | ||
| */ | ||
| public class JDKLatest implements BooleanSupplier { | ||
| @Override | ||
| public boolean getAsBoolean() { | ||
| return JavaVersionUtil.JAVA_SPEC <= 22; | ||
| return JavaVersionUtil.JAVA_SPEC > 21; | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Nitpick: I understand that
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. From my perspective, that is just an implementation detail. |
||
| } | ||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it make sense to move this map in a package that is accessible here and actually reference the highest key instead of hardcoding the check to
21?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The package is accessible, it is just the field that is
private. The LTS version change so seldomly that IMHO it is fine to have a few references to it.