RFR: 8177650: JShell tool: packages in classpath don't appear in completions [v3]
Adam Sotona
asotona at openjdk.org
Tue Aug 26 12:06:39 UTC 2025
On Thu, 14 Aug 2025 08:31:08 GMT, Jan Lahoda <jlahoda at openjdk.org> wrote:
>> JShell provides the code completion feature, where it suggests possible follow ups for a given snippet prefix. To allow completion for packages, JShell uses a background task to go through known classes and create an index for them.
>>
>> There are two problems with this background task:
>> - the classpath is read from the JShell's FileManager, but the FileManager may not be configured with the compile options yet, so the classpath may not be filled yet,
>> - the module path is not included in the list of paths to paths to search
>>
>> This PR proposes to:
>> - use FileManager configured by passing the compile options through javac
>> - include the module path in the search path
>
> Jan Lahoda 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 six additional commits since the last revision:
>
> - Reading module paths directly from the FileManager, to avoid playing with JRT FS.
> - Merge branch 'master' into JDK-8177650
> - Avoiding problems with locked files on Windows.
> - Correcting handling of modular paths.
> - Improving test reliability.
> - 8177650: JShell tool: packages in classpath don't appear in completions
Marked as reviewed by asotona (Reviewer).
-------------
PR Review: https://git.openjdk.org/jdk/pull/26137#pullrequestreview-3155330016
More information about the kulla-dev
mailing list