RFR: JDK-8187681: Compiling for target 9 while also using --patch-module
Jonathan Gibbons
jonathan.gibbons at oracle.com
Tue Oct 31 20:27:50 UTC 2017
Basic patch is OK.
I understand Maurizio's use case, but I also agree with Jan's analysis
of what is entailed. If we want to relax the restriction of -source and
--patch-module, it should be a separate patch.
-- Jon
On 10/12/2017 08:48 AM, Jan Lahoda wrote:
> On 12.10.2017 17:26, Maurizio Cimadamore wrote:
>> Whoops - hit send too fast - wanted to ask a question; do you also plan
>> to remove similar restriction for -source ? I've hit that a couple of
>> times, and currently this restriction is preventing me from running
>> langtools tests on a patched compiler; that is, I can patch the VM to
>> run the tests and that works, but I can't pass same set of patches to
>> the javac used by jtreg, as that will result in errors whenever a test
>> has e.g. -source 8 flag set.
>
> I am afraid this is more involved. The restriction removed here is
> mostly for consistency with restricting --add-exports for system
> modules with --release, which is mostly for safety. So this is mostly
> deleting a check.
>
> Allowing --patch-module with -source < 9 is more complex, as it means
> actually changing the file manager to reflect the option for
> StandardLocation.PLATFORM_CLASS_PATH (and check there's no
> -bootclasspath, combined with --patch-module, as that would not make
> much sense). But might still be possible. Jon, any comment?
>
> Thanks,
> Jan
>
>>
>> Maurizio
>>
>>
>>
>> On 12/10/17 16:24, Maurizio Cimadamore wrote:
>>> Looks good
>>>
>>> Maurizio
>>>
>>>
>>> On 12/10/17 16:04, Jan Lahoda wrote:
>>>> Hello,
>>>>
>>>> I'd like to ask for a review for:
>>>> Bug: https://bugs.openjdk.java.net/browse/JDK-8187681
>>>> Webrev: http://cr.openjdk.java.net/~jlahoda/8187681/webrev.00/
>>>>
>>>> The patch is basically to remove the limitation on use of
>>>> --patch-module for a system module in combination with --release.
>>>>
>>>> Thanks,
>>>> Jan
>>>
>>
More information about the compiler-dev
mailing list