RFR: 8352612: No way to add back lint categories after "none" [v4]
Maurizio Cimadamore
mcimadamore at openjdk.org
Thu Apr 10 21:06:40 UTC 2025
On Thu, 10 Apr 2025 19:27:21 GMT, Archie Cobbs <acobbs at openjdk.org> wrote:
>> src/jdk.compiler/share/man/javac.md line 564:
>>
>>> 562:
>>> 563: <a id="option-Xlint-custom">`-Xlint:`\[`-`\]*key*(`,`\[`-`\]*key*)\*</a>
>>> 564: : Specifies warning categories to enable or disable, separated by comma.
>>
>> This text uses `categories` and `key` in a very loose way -- they seem to refer to the same concept, yet none seems to be defined.
>>
>>
>> Enables or disables selected warning categories. Each warning category is identified by a key. Some keys allow multiple categories to be enabled or disabled in bulk. Keys are separated by a comma. Precede a key by a hyphen (-) to disable the corresponding warning category.
>>
>> Supported keys are:
>> ...
>>
>>
>> What do you think?
>
> Yes more words are helpful. I think we also need to say that `all` and `none` can't be preceded by a hyphen (I just learned this not long ago :)
>
> What do you think about this?
>
> <a id="option-Xlint-custom">`-Xlint:`[`-`]*key*(`,`[`-`]*key*)*</a>
> : Enables and/or disables selected warning categories. Categories are identified by one or more
> keys separated by commas. Keys preceded by a hyphen (`-`) disable the corresponding category;
> hyphens are not supported by the special keys `all` and `none`.
It's good --- but I guess I liked to say that a key was either a warning category (serial) or something to enable/disable things in bulk (all/none). This is now missing in the new text.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/24227#discussion_r2038336190
More information about the compiler-dev
mailing list