RFR: 8336470: Source launcher should work with service loader SPI in unnamed module [v15]

Christian Stein cstein at openjdk.org
Fri May 16 10:40:57 UTC 2025


On Fri, 16 May 2025 05:25:33 GMT, Alan Bateman <alanb at openjdk.org> wrote:

>> Christian Stein has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains 12 additional commits since the last revision:
>> 
>>  - Merge branch 'openjdk:master' into JDK-8336470-source-launcher-get-resources
>>  - Revert change after JDK-8356678 being addressed
>>  - Prevent FileSystemException on Unix-based file systems
>>  - Prevent NPE by removing redundant check
>>  - Removed redundant catch block
>>  - Catch and rethrow IO exception
>>  - Fix interim javac compilation
>>  - Reuse internal resource resolver and remove confusing comment
>>  - Update copyright year
>>    
>>    [skip ci]
>>  - User copyright text w/o `"Classpath" exception`
>>    
>>    [skip ci]
>>  - ... and 2 more: https://git.openjdk.org/jdk/compare/30d5d804...11956f24
>
> src/jdk.compiler/share/classes/com/sun/tools/javac/launcher/MemoryClassLoader.java line 284:
> 
>> 282:             var path = Resources.toFilePath(programDescriptor.sourceRootPath(), name);
>> 283:             return path == null ? null : path.toUri().toURL();
>> 284:         } catch (IOException e) {
> 
> toUri throws IOError so I think you will need handle this too, otherwise I think the updated toResourceInRootPath looks okay.

Caught and handled in https://github.com/openjdk/jdk/pull/20193/commits/6a0db8a6c7e630e37a431463b67749303a6e3d13

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

PR Review Comment: https://git.openjdk.org/jdk/pull/20193#discussion_r2092803350


More information about the compiler-dev mailing list