[code-reflection] RFR: Regression: compiler SPI does not work with exploded build

Maurizio Cimadamore mcimadamore at openjdk.org
Fri Nov 22 11:06:52 UTC 2024


On Thu, 21 Nov 2024 23:18:30 GMT, Paul Sandoz <psandoz at openjdk.org> wrote:

> To be on the safe side should we do it like the following?
> 
> ```
>             if (ModuleLayer.boot().findModule("jdk.incubator.code").isPresent()) {
>                 CODE_LAYER = ModuleLayer.boot();
>             } else if (java.lang.module.ModuleFinder.ofSystem().find("jdk.incubator.code").isPresent()) {
>             ...
>             } else {
>                 // if we run javac in bootstrap mode, there might be no jdk.incubator.code
>                 CODE_LAYER = null;
>             }
> ```

Yeah, this might be a good idea.

-------------

PR Comment: https://git.openjdk.org/babylon/pull/278#issuecomment-2493494140


More information about the babylon-dev mailing list