On Wed, 6 Oct 2021 05:04:28 GMT, Ichiroh Takiguchi <itakigu...@openjdk.org> 
wrote:

>> JEP-400 (UTF-8 by Default) was eabled on JDK18-b13.
>> After JDK18-b13, javac and some other langtool command's usage were garbled 
>> on Japanese Windows.
>> These commands use PrintWriter instead of standard out/err with PrintStream.
>
> Ichiroh Takiguchi has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   8274544: Langtools command's usage were garbled on Japanese Windows

I got your issue now. Since the current code issues `FileReader()` without 
specifying the explicit charset, this is the prime example that is affected by 
the JEP. The question is, in which encoding the jshell save file should be? I 
think it belongs to the spec of jshell, and it should be specified somewhere in 
the document.

BTW, the suggestion I made in `JShellToolProvider` still holds regardless of 
the save file issue.

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

PR: https://git.openjdk.java.net/jdk/pull/5771

Reply via email to