RFR: 8153652 Update javap to be multi-release jar aware
Alan Bateman
Alan.Bateman at oracle.com
Tue Jun 14 19:34:18 UTC 2016
On 14/06/2016 18:16, Steve Drach wrote:
>>> Please review the following changeset that simply supplies the help
>>> information for the already existing javap command line option,
>>> -multi-release.
>>>
>>> webrev: http://cr.openjdk.java.net/~sdrach/8153652/webrev.00/
>>> <http://cr.openjdk.java.net/%7Esdrach/8153652/webrev.00/>
>>> <http://cr.openjdk.java.net/~sdrach/8153652/webrev.00/
>>> <http://cr.openjdk.java.net/%7Esdrach/8153652/webrev.00/>>
>>> issue: https://bugs.openjdk.java.net/browse/JDK-8153652
>>> <https://bugs.openjdk.java.net/browse/JDK-8153652>
>>>
>>> It turns out that javap forwards unrecognized command line options
>>> to the JavaFileManager for processing. One such option is
>>> -multi-release. The value that the -multi-release option is set to
>>> is used by JavaFileManager to open multi-release jar files so that
>>> the appropriate versioned view is presented to the client, javap in
>>> this case. All this changeset does is add a help message describing
>>> the existing -multi-release command line option.
>>>
>>> The values that can be assigned to this option, and the
>>> corresponding multi-release modes that the jar file is configured
>>> for are:
>>>
>>> 9 -> JarFile.Release.VERSION_9
>>> runtime -> JarFile.Release.RUNTIME
>>> all others -> JarFile.Release.BASE
>>>
>>> If the option is not present, the jar file mode is JarFile.Release.Base.
>>>
>> Is -multi-release the agreed option? Just curious as I would have
>> expected -multirelease. If GNU style then it would be --multi-release
>> of course.
>
> -multi-release is the option defined in javac options
Is that in JDK 9 yet? It doesn't seem consistent with options like
-processor path, -modulepath, and other multi-word options. Also if were
to add GNU style then it might mean -multi-release and --multi-release.
-Alan
More information about the core-libs-dev
mailing list