-
Notifications
You must be signed in to change notification settings - Fork 6.1k
8359596: Behavior change when both -Xlint:options and -Xlint:-options flags are given #25840
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
base: master
Are you sure you want to change the base?
Conversation
👋 Welcome back acobbs! A progress list of the required criteria for merging this PR into |
❗ This change is not yet ready to be integrated. |
@archiecobbs The following label will be automatically applied to this pull request:
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. |
Webrevs
|
/csr needed |
@jddarcy has indicated that a compatibility and specification (CSR) request is needed for this pull request. @archiecobbs please create a CSR request for issue JDK-8359596 with the correct fix version. This pull request cannot be integrated until the CSR request is approved. |
The extra checks for "-Xlint:none" are needed now because of JDK-8352612, which changed the behavior of "-Xlint:none" to no longer imply "-nowarn", which allowed the affected warnings to get away with skipping that check.
Adding Possibly at a later stage we should centralize all the handling using an EnumSet which is populated only once before the compiler is invoked. The behaviour should be documented in the javac documentation. |
My minor contribution to #24746 (which fixed JDK-8354556) accidentally introduced a change in the compiler's behavior when given conflicting lint flags like
-Xlint:options -Xlint:-options
. This PR restores the original behavior.Although this might be considered a weird corner case, many build systems add flags in multiple stages and this can easily result in both flags being added, and so the behavior in this scenario needs to stay consistent.
Basically the code was trying to be too clever; when the original logic is restored, the code gets simpler.
Progress
Issues
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/25840/head:pull/25840
$ git checkout pull/25840
Update a local copy of the PR:
$ git checkout pull/25840
$ git pull https://git.openjdk.org/jdk.git pull/25840/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 25840
View PR using the GUI difftool:
$ git pr show -t 25840
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/25840.diff
Using Webrev
Link to Webrev Comment